public interface UTF8EncoderInterface for an external UTF8 Encoder that can be supplied by a client which implements custom encoding logic optimized for the application using the Codec.
ProtonBuffer encodeUTF8(ProtonBuffer buffer, java.lang.CharSequence sequence)Encodes the given sequence of characters in UTF8 to the given buffer.
buffer- A ProtonBuffer where the UTF-8 encoded bytes should be written.
CharSequencerepresenting the UTF-8 bytes to encode
- a reference to the encoding buffer for chaining