
public class SpdyFrameDecoder extends FrameDecoder
ChannelBuffers into SPDY Frames.ChannelHandler.Sharablecumulation, DEFAULT_MAX_COMPOSITEBUFFER_COMPONENTS| Modifier | Constructor and Description |
|---|---|
|
SpdyFrameDecoder(SpdyVersion spdyVersion)
Creates a new instance with the specified
version and the default
maxChunkSize (8192) and maxHeaderSize (16384). |
|
SpdyFrameDecoder(SpdyVersion spdyVersion,
int maxChunkSize,
int maxHeaderSize)
Creates a new instance with the specified parameters.
|
protected |
SpdyFrameDecoder(SpdyVersion spdyVersion,
int maxChunkSize,
org.jboss.netty.handler.codec.spdy.SpdyHeaderBlockDecoder headerBlockDecoder) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
cleanup(ChannelHandlerContext ctx,
ChannelStateEvent e)
|
protected Object |
decode(ChannelHandlerContext ctx,
Channel channel,
ChannelBuffer buffer)
Decodes the received packets so far into a frame.
|
actualReadableBytes, afterAdd, afterRemove, appendToCumulation, beforeAdd, beforeRemove, channelClosed, channelDisconnected, decodeLast, exceptionCaught, extractFrame, getMaxCumulationBufferCapacity, getMaxCumulationBufferComponents, internalBuffer, isUnfold, messageReceived, newCumulationBuffer, replace, setMaxCumulationBufferCapacity, setMaxCumulationBufferComponents, setUnfold, unfoldAndFireMessageReceived, updateCumulationchannelBound, channelConnected, channelInterestChanged, channelOpen, channelUnbound, childChannelClosed, childChannelOpen, handleUpstream, writeCompletepublic SpdyFrameDecoder(SpdyVersion spdyVersion)
version and the default
maxChunkSize (8192) and maxHeaderSize (16384).public SpdyFrameDecoder(SpdyVersion spdyVersion, int maxChunkSize, int maxHeaderSize)
protected SpdyFrameDecoder(SpdyVersion spdyVersion, int maxChunkSize, org.jboss.netty.handler.codec.spdy.SpdyHeaderBlockDecoder headerBlockDecoder)
protected Object decode(ChannelHandlerContext ctx, Channel channel, ChannelBuffer buffer) throws Exception
FrameDecoderFrameDecoder.extractFrame(ChannelBuffer, int, int) method,
to make optimizations easier later.decode in class FrameDecoderctx - the context of this handlerchannel - the current channelbuffer - the cumulative buffer of received packets so far.
Note that the buffer might be empty, which means you
should not make an assumption that the buffer contains
at least one byte in your decoder implementation.null if there's not enough data in the buffer to decode a frame.Exceptionprotected void cleanup(ChannelHandlerContext ctx, ChannelStateEvent e) throws Exception
FrameDecoderFrameDecoder.channelDisconnected(ChannelHandlerContext, ChannelStateEvent) and
FrameDecoder.channelClosed(ChannelHandlerContext, ChannelStateEvent)cleanup in class FrameDecoderExceptionCopyright © 2008-2014 The Netty Project. All Rights Reserved.