public class ReflectionMessageCodec<T> extends Object implements MessageCodec
Constructor and Description |
---|
ReflectionMessageCodec(Class<T> clazz,
MethodHandle parseMethod,
MethodHandle encodeMethod) |
Modifier and Type | Method and Description |
---|---|
void |
encode(ProtocolOptions options,
Object msg,
io.netty.buffer.ByteBuf out) |
T |
parse(ProtocolOptions options,
byte length,
ASDUHeader header,
io.netty.buffer.ByteBuf data) |
public ReflectionMessageCodec(Class<T> clazz, MethodHandle parseMethod, MethodHandle encodeMethod)
public T parse(ProtocolOptions options, byte length, ASDUHeader header, io.netty.buffer.ByteBuf data)
parse
in interface MessageCodec
public void encode(ProtocolOptions options, Object msg, io.netty.buffer.ByteBuf out)
encode
in interface MessageCodec