@SpiMeta(name="motan2") public class MotanV2Codec extends AbstractCodec
serializations| Constructor and Description |
|---|
MotanV2Codec() |
| Modifier and Type | Method and Description |
|---|---|
Object |
decode(Channel channel,
String remoteIp,
byte[] data)
decode data
|
byte[] |
encode(Channel channel,
Object message) |
createInput, createOutput, deserialize, getSerializationByNum, initAllSerialization, serializepublic byte[] encode(Channel channel, Object message) throws IOException
IOExceptionpublic Object decode(Channel channel, String remoteIp, byte[] data) throws IOException
remoteIp - 用来在server端decode request时能获取到client的ip。IOExceptionCopyright © 2019. All rights reserved.