Callback.Adapter
Modifier and Type | Method and Description |
---|---|
void |
associate(IStream stream)
|
void |
disassociate(IStream stream)
remove the given associated
IStream from this stream |
IStream |
getAssociatedStream()
Overrides Stream.getAssociatedStream() to return an instance of IStream instead of Stream
|
StreamFrameListener |
getStreamFrameListener() |
int |
getWindowSize()
Senders of data frames need to know the current window size
to determine whether they can send more data.
|
void |
process(ControlFrame frame)
Processes the given control frame,
for example by updating the stream's state or by calling listeners.
|
void |
process(DataInfo dataInfo)
Processes the given
dataInfo ,
for example by updating the stream's state or by calling listeners. |
void |
setStreamFrameListener(StreamFrameListener listener) |
void |
updateCloseState(boolean close,
boolean local)
A stream can be open,
half closed or
closed and this method updates the close state
of this stream. |
void |
updateWindowSize(int delta)
Updates the window size for this stream by the given amount,
that can be positive or negative.
|
data, data, getAttribute, getId, getIdleTimeout, getPriority, getPushedStreams, getSession, headers, headers, isClosed, isHalfClosed, isReset, isUnidirectional, push, push, removeAttribute, reply, reply, setAttribute, setIdleTimeout
int getWindowSize()
Senders of data frames need to know the current window size to determine whether they can send more data.
updateWindowSize(int)
void updateWindowSize(int delta)
Updates the window size for this stream by the given amount, that can be positive or negative.
Senders and recipients of data frames update the window size, respectively, with negative values and positive values.
delta
- the signed amount the window size needs to be updatedgetWindowSize()
void setStreamFrameListener(StreamFrameListener listener)
listener
- the stream frame listener associated to this stream
as returned by SessionFrameListener.onSyn(Stream, SynInfo)
StreamFrameListener getStreamFrameListener()
void updateCloseState(boolean close, boolean local)
A stream can be open, half closed
or
closed
and this method updates the close state
of this stream.
If the stream is open, calling this method with a value of true puts the stream into half closed state.
If the stream is half closed, calling this method with a value of true puts the stream into closed state.
close
- whether the close state should be updatedlocal
- whether the close is local or remotevoid process(ControlFrame frame)
Processes the given control frame, for example by updating the stream's state or by calling listeners.
frame
- the control frame to processprocess(DataInfo)
void process(DataInfo dataInfo)
Processes the given dataInfo
,
for example by updating the stream's state or by calling listeners.
dataInfo
- the DataInfo to processprocess(ControlFrame)
void associate(IStream stream)
stream
- the stream to associate with this streamvoid disassociate(IStream stream)
remove the given associated IStream
from this stream
stream
- the stream to be removedIStream getAssociatedStream()
Overrides Stream.getAssociatedStream() to return an instance of IStream instead of Stream
getAssociatedStream
in interface Stream
Stream.getAssociatedStream()
Copyright © 1995-2015 Webtide. All Rights Reserved.