Package io.netty.handler.codec.spdy
Class DefaultSpdyDataFrame
- java.lang.Object
-
- io.netty.handler.codec.spdy.DefaultSpdyStreamFrame
-
- io.netty.handler.codec.spdy.DefaultSpdyDataFrame
-
- All Implemented Interfaces:
io.netty.buffer.ByteBufHolder,SpdyDataFrame,SpdyFrame,SpdyStreamFrame,io.netty.util.ReferenceCounted
public class DefaultSpdyDataFrame extends DefaultSpdyStreamFrame implements SpdyDataFrame
The defaultSpdyDataFrameimplementation.
-
-
Constructor Summary
Constructors Constructor Description DefaultSpdyDataFrame(int streamId)Creates a new instance.DefaultSpdyDataFrame(int streamId, io.netty.buffer.ByteBuf data)Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description io.netty.buffer.ByteBufcontent()Returns the data payload of this frame.SpdyDataFramecopy()SpdyDataFrameduplicate()intrefCnt()booleanrelease()booleanrelease(int decrement)SpdyDataFramereplace(io.netty.buffer.ByteBuf content)SpdyDataFrameretain()SpdyDataFrameretain(int increment)SpdyDataFrameretainedDuplicate()SpdyDataFramesetLast(boolean last)Sets if this frame is the last frame to be transmitted on the stream.SpdyDataFramesetStreamId(int streamId)Sets the Stream-ID of this frame.StringtoString()SpdyDataFrametouch()SpdyDataFrametouch(Object hint)-
Methods inherited from class io.netty.handler.codec.spdy.DefaultSpdyStreamFrame
isLast, streamId
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface io.netty.handler.codec.spdy.SpdyStreamFrame
isLast, streamId
-
-
-
-
Constructor Detail
-
DefaultSpdyDataFrame
public DefaultSpdyDataFrame(int streamId)
Creates a new instance.- Parameters:
streamId- the Stream-ID of this frame
-
DefaultSpdyDataFrame
public DefaultSpdyDataFrame(int streamId, io.netty.buffer.ByteBuf data)Creates a new instance.- Parameters:
streamId- the Stream-ID of this framedata- the payload of the frame. Can not exceedSpdyCodecUtil.SPDY_MAX_LENGTH
-
-
Method Detail
-
setStreamId
public SpdyDataFrame setStreamId(int streamId)
Description copied from interface:SpdyStreamFrameSets the Stream-ID of this frame. The Stream-ID must be positive.- Specified by:
setStreamIdin interfaceSpdyDataFrame- Specified by:
setStreamIdin interfaceSpdyStreamFrame- Overrides:
setStreamIdin classDefaultSpdyStreamFrame
-
setLast
public SpdyDataFrame setLast(boolean last)
Description copied from interface:SpdyStreamFrameSets if this frame is the last frame to be transmitted on the stream.- Specified by:
setLastin interfaceSpdyDataFrame- Specified by:
setLastin interfaceSpdyStreamFrame- Overrides:
setLastin classDefaultSpdyStreamFrame
-
content
public io.netty.buffer.ByteBuf content()
Description copied from interface:SpdyDataFrameReturns the data payload of this frame. If there is no data payloadUnpooled.EMPTY_BUFFERis returned. The data payload cannot exceed 16777215 bytes.- Specified by:
contentin interfaceio.netty.buffer.ByteBufHolder- Specified by:
contentin interfaceSpdyDataFrame
-
copy
public SpdyDataFrame copy()
- Specified by:
copyin interfaceio.netty.buffer.ByteBufHolder- Specified by:
copyin interfaceSpdyDataFrame
-
duplicate
public SpdyDataFrame duplicate()
- Specified by:
duplicatein interfaceio.netty.buffer.ByteBufHolder- Specified by:
duplicatein interfaceSpdyDataFrame
-
retainedDuplicate
public SpdyDataFrame retainedDuplicate()
- Specified by:
retainedDuplicatein interfaceio.netty.buffer.ByteBufHolder- Specified by:
retainedDuplicatein interfaceSpdyDataFrame
-
replace
public SpdyDataFrame replace(io.netty.buffer.ByteBuf content)
- Specified by:
replacein interfaceio.netty.buffer.ByteBufHolder- Specified by:
replacein interfaceSpdyDataFrame
-
refCnt
public int refCnt()
- Specified by:
refCntin interfaceio.netty.util.ReferenceCounted
-
retain
public SpdyDataFrame retain()
- Specified by:
retainin interfaceio.netty.buffer.ByteBufHolder- Specified by:
retainin interfaceio.netty.util.ReferenceCounted- Specified by:
retainin interfaceSpdyDataFrame
-
retain
public SpdyDataFrame retain(int increment)
- Specified by:
retainin interfaceio.netty.buffer.ByteBufHolder- Specified by:
retainin interfaceio.netty.util.ReferenceCounted- Specified by:
retainin interfaceSpdyDataFrame
-
touch
public SpdyDataFrame touch()
- Specified by:
touchin interfaceio.netty.buffer.ByteBufHolder- Specified by:
touchin interfaceio.netty.util.ReferenceCounted- Specified by:
touchin interfaceSpdyDataFrame
-
touch
public SpdyDataFrame touch(Object hint)
- Specified by:
touchin interfaceio.netty.buffer.ByteBufHolder- Specified by:
touchin interfaceio.netty.util.ReferenceCounted- Specified by:
touchin interfaceSpdyDataFrame
-
release
public boolean release()
- Specified by:
releasein interfaceio.netty.util.ReferenceCounted
-
release
public boolean release(int decrement)
- Specified by:
releasein interfaceio.netty.util.ReferenceCounted
-
-