public static String decode(ByteBuffer buff) throws CharacterCodingException {
  CharBuffer chars=UTF8Decoder.decode(buff);
  return chars.toString();
}

public static String decode ( ByteBuffer buff ) throws CharacterCodingException { CharBuffer chars = UTF8Decoder . decode ( buff ) ; return chars . toString ( ) ; }
decode ' % ' - escaped characters . decoding fails in case of invalid utf - 8
