public interface Channel extends ChannelListenerManager, PropertyResolver, Closeable
Modifier and Type | Field and Description |
---|---|
static String |
CHANNEL_EXEC |
static String |
CHANNEL_SHELL |
static String |
CHANNEL_SUBSYSTEM |
Modifier and Type | Method and Description |
---|---|
int |
getId() |
Window |
getLocalWindow() |
int |
getRecipient() |
Window |
getRemoteWindow() |
Session |
getSession() |
void |
handleClose() |
void |
handleData(Buffer buffer) |
void |
handleEof() |
void |
handleExtendedData(Buffer buffer) |
void |
handleFailure()
Handle channel request failure
|
void |
handleOpenFailure(Buffer buffer)
For a client channel, this method will be called internally by the
session when the server has rejected this channel opening.
|
void |
handleOpenSuccess(int recipient,
int rwSize,
int packetSize,
Buffer buffer)
For a client channel, this method will be called internally by the
session when the confirmation has been received.
|
void |
handleRequest(Buffer buffer) |
void |
handleSuccess()
Handle channel request success
|
void |
handleWindowAdjust(Buffer buffer) |
void |
init(ConnectionService service,
Session session,
int id) |
OpenFuture |
open(int recipient,
int rwSize,
int packetSize,
Buffer buffer)
For a server channel, this method will actually open the channel
|
addChannelListener, getChannelListenerProxy, removeChannelListener
getParentPropertyResolver, getProperties
static final String CHANNEL_EXEC
static final String CHANNEL_SHELL
static final String CHANNEL_SUBSYSTEM
int getId()
int getRecipient()
Window getLocalWindow()
Window getRemoteWindow()
void handleClose() throws IOException
IOException
void handleWindowAdjust(Buffer buffer) throws IOException
IOException
void handleRequest(Buffer buffer) throws IOException
IOException
void handleData(Buffer buffer) throws IOException
IOException
void handleExtendedData(Buffer buffer) throws IOException
IOException
void handleEof() throws IOException
IOException
void handleSuccess() throws IOException
IOException
- If failed to handlevoid handleFailure() throws IOException
IOException
- If failed to handlevoid init(ConnectionService service, Session session, int id) throws IOException
IOException
OpenFuture open(int recipient, int rwSize, int packetSize, Buffer buffer)
recipient
- Recipient identifierrwSize
- Read/Write window sizepacketSize
- Preferred maximum packet sizebuffer
- Incoming Buffer
that triggered the call.
Note: the buffer's read position is exactly
after the information that read to this call
was decodedOpenFuture
for the channel open requestvoid handleOpenSuccess(int recipient, int rwSize, int packetSize, Buffer buffer) throws IOException
recipient
- Recipient identifierrwSize
- Read/Write window sizepacketSize
- Preferred maximum packet sizebuffer
- Incoming Buffer
that triggered the call.
Note: the buffer's read position is exactly
after the information that read to this call
was decodedIOException
- If failed to handle the successvoid handleOpenFailure(Buffer buffer) throws IOException
buffer
- Incoming Buffer
that triggered the call.
Note: the buffer's read position is exactly
after the information that read to this call
was decodedIOException
- If failed to handle the successCopyright © 2008–2016 The Apache Software Foundation. All rights reserved.