public interface ProtocolEncoder
encode(IoSession, Object, ProtocolEncoderOutput)
method with message which is popped from the session write queue, and then
the encoder implementation puts encoded messages (typically IoBuffers)
into ProtocolEncoderOutput by calling ProtocolEncoderOutput.write(Object).
Please refer to
TextLineEncoder
example.
ProtocolEncoderExceptionvoid encode(IoSession session, Object message, ProtocolEncoderOutput out) throws Exception
encode(IoSession, Object, ProtocolEncoderOutput)
method with message which is popped from the session write queue, and then
the encoder implementation puts encoded messages (typically IoBuffers)
into ProtocolEncoderOutput.Exception - if the message violated protocol specification