Compressing Unicode text for transmission or storage results in minimal bandwidth usage and fewer storage devices. The compression scheme compresses Unicode text into a sequence of bytes by using characteristics of Unicode text. The compressed sequence can be used on its own or as further input to a general purpose file or disk-block based compression scheme. Note that the combination of the Unicode compression algorithm plus disk-block based compression produces better results than either method alone.
Strings in languages using small alphabets contain runs of characters that are coded close together in Unicode. These runs are typically interrupted only by punctuation characters, which are themselves coded in proximity to each other in Unicode (usually in the Basic Latin range).
For additional detail about the compression algorithm, which has been approved by the Unicode Consortium, please refer to Unicode Technical Report #6 (A Standard Compression Scheme for Unicode) .
The Standard Compression Scheme for Unicode (SCSU) is used to:
It does not attempt to avoid the use of control bytes (including NUL) in the compressed stream.
The compression scheme is mainly intended for use with short to medium length Unicode strings. The resulting compressed format is intended for storage or transmission in bandwidth limited environments. It can be used stand-alone or as input to traditional general purpose data compression schemes. It is not intended as processing format or as general purpose interchange format.
A MIME compatible encoding called BOCU-1 is also available in ICU. Details about this encoding can be found in the Unicode Technical Note #6 . Both SCSU and BOCU-1 are IANA registered names.
The compression service in ICU is a part of Conversion framework, and follows the semantics of converters. For more information on how to use ICU's conversion service, please refer to the Usage Model section in the Using Converters chapter.