public class SpdyFrameDecoder extends ByteToMessageDecoder
ByteBuf
s into SPDY Data and Control Frames.ChannelHandler.Sharable
Constructor and Description |
---|
SpdyFrameDecoder(int version)
Creates a new instance with the specified
version and the default
maxChunkSize (8192) and maxHeaderSize (16384) . |
SpdyFrameDecoder(int version,
int maxChunkSize,
int maxHeaderSize)
Creates a new instance with the specified parameters.
|
Modifier and Type | Method and Description |
---|---|
protected Object |
decode(ChannelHandlerContext ctx,
ByteBuf buffer)
Decode the from one
ByteBuf to an other. |
Object |
decodeLast(ChannelHandlerContext ctx,
ByteBuf in)
Is called one last time when the
ChannelHandlerContext goes in-active. |
callDecode, channelInactive, channelReadSuspended, inboundBufferUpdated, isSingleDecode, setSingleDecode
discardInboundReadBytes, freeInboundBuffer, inboundBufferUpdated, newInboundBuffer
channelActive, channelRegistered, channelUnregistered, userEventTriggered
afterAdd, afterRemove, beforeAdd, beforeRemove, exceptionCaught
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
channelActive, channelRegistered, channelUnregistered, userEventTriggered
afterAdd, afterRemove, beforeAdd, beforeRemove, exceptionCaught
public SpdyFrameDecoder(int version)
version
and the default
maxChunkSize (8192)
and maxHeaderSize (16384)
.public SpdyFrameDecoder(int version, int maxChunkSize, int maxHeaderSize)
public Object decodeLast(ChannelHandlerContext ctx, ByteBuf in) throws Exception
ByteToMessageDecoder
ChannelHandlerContext
goes in-active. Which means the
ByteToMessageDecoder.channelInactive(ChannelHandlerContext)
was triggered.
By default this will just call ByteToMessageDecoder.decode(ChannelHandlerContext, ByteBuf)
but sub-classes may
override this for some special cleanup operation.decodeLast
in class ByteToMessageDecoder
Exception
protected Object decode(ChannelHandlerContext ctx, ByteBuf buffer) throws Exception
ByteToMessageDecoder
ByteBuf
to an other. This method will be called till either the input
ByteBuf
has nothing to read anymore, till nothing was read from the input ByteBuf
or till
this method returns null
.decode
in class ByteToMessageDecoder
ctx
- the ChannelHandlerContext
which this ByteToByteDecoder
belongs tobuffer
- the ByteBuf
from which to read dataByteBuf
was decoded, or null
if
there was not enough data left in the ByteBuf
to decode.Exception
- is thrown if an error accourCopyright © 2008-2013 The Netty Project. All Rights Reserved.