code: public static char [] decompress(byte [] buffer, int start, int limit) {
          UnicodeDecompressor comp = new UnicodeDecompressor();
      
          // use a buffer we know will never overflow
          // in the worst case, each byte will decompress
          // to a surrogate pair (buffer must be at least 2 chars)
          int len = Math.max(2, 2 * (limit - start));
          char [] temp = new char [len];
      
          int charCount = comp.decompress(buffer, start, limit, null, 
                          temp, 0, len);
      
          char [] result = new char [charCount];
          System.arraycopy(temp, 0, result, 0, charCount);
          return result;
      }
docs: Decompress a byte array into a Unicode character array.
  @param buffer The byte array to decompress.
  @param start The start of the byte run to decompress.
  @param limit The limit of the byte run to decompress.
  @return A character array containing the decompressed bytes.
  @see #decompress(byte [])