public class JsonRpcDecoder
extends io.netty.handler.codec.ByteToMessageDecoder
There are no JSON parsers that I am aware of that does non blocking parsing. This approach avoids having to run json parser over and over again on the entire stream waiting for input. Parser is invoked only when we know of a full JSON message in the stream.
Constructor and Description |
---|
JsonRpcDecoder(int maxFrameLength) |
Modifier and Type | Method and Description |
---|---|
protected void |
decode(io.netty.channel.ChannelHandlerContext ctx,
io.netty.buffer.ByteBuf buf,
List<Object> out) |
int |
getRecordsRead() |
actualReadableBytes, callDecode, channelInactive, channelRead, channelReadComplete, decodeLast, discardSomeReadBytes, handlerRemoved, handlerRemoved0, internalBuffer, isSingleDecode, setCumulator, setDiscardAfterReads, setSingleDecode, userEventTriggered
channelActive, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaught
Copyright © 2018 OpenDaylight. All rights reserved.