public void encode ( ByteBuf out , CharSequence data ) { ObjectUtil . checkNotNull ( out , "out" ) ; if ( data instanceof AsciiString ) { AsciiString string = ( AsciiString ) data ; try { encodeProcessor . out = out ; string . forEachByte ( encodeProcessor ) ; } catch ( Exception e ) { PlatformDependent . throwException ( e ) ; } finally { encodeProcessor . end ( ) ; } } else { encodeSlowPath ( out , data ) ; } }
Compresses the input string literal using the Huffman coding .