DefaultSshFuture that can be used to wait for the reply of an SSH_MSG_GLOBAL_REQUEST sent with
want-reply = true.
org.apache.sshd.common.session.Session#request(Buffer, String, ReplyHandler)
| Modifier and Type | Class and Description |
|---|---|
| public static interface | GlobalRequestFuture.
A |
| Modifier and Type | Field and Description |
|---|---|
| private final GlobalRequestFuture. | |
| private long |
| Access | Constructor and Description |
|---|---|
| public | GlobalRequestFuture(String
the request identifier request)Creates a new |
| public | GlobalRequestFuture(String
the request identifier request, GlobalRequestFuture.the handlerReplyHandler, or nullCreates a new |
| Modifier and Type | Method and Description |
|---|---|
| public Buffer | |
| public Throwable | Returns: a failure reason, ornull if there isn't one or if the request did not failImplements org. Retrieves an exception if the request failed. |
| public GlobalRequestFuture. | Returns: the handler, ornull if none was setRetrieves the |
| public String | |
| public long | |
| public void | operationComplete(IoWriteFuture
The source future)SshFuture which called this callback.Implements org. Invoked when the operation associated with the |
| public void | setSequenceNumber(long
the packet sequence number number)Sets the packet sequence number of the global request represented by this future. |
| public String | toString()
Overrides org. Returns a string representation of the object. |
| handler | back to summary |
|---|---|
| private final GlobalRequestFuture. | |
| sequenceNumber | back to summary |
|---|---|
| private long sequenceNumber | |
| GlobalRequestFuture | back to summary |
|---|---|
| public GlobalRequestFuture(String request) Creates a new
| |
| GlobalRequestFuture | back to summary |
|---|---|
| public GlobalRequestFuture(String request, GlobalRequestFuture. Creates a new
| |
| getBuffer | back to summary |
|---|---|
| public Buffer getBuffer() Obtains the reply | |
| getException | back to summary |
|---|---|
| public Throwable getException() Implements org. Retrieves an exception if the request failed. If called after | |
| getHandler | back to summary |
|---|---|
| public GlobalRequestFuture. Retrieves the
| |
| getId | back to summary |
|---|---|
| public String getId() Overrides org. Implements org.
| |
| getSequenceNumber | back to summary |
|---|---|
| public long getSequenceNumber() Retrieves this future's packet sequence number.
| |
| operationComplete | back to summary |
|---|---|
| public void operationComplete(IoWriteFuture future) Implements org. Doc from org. Invoked when the operation associated with the
| |
| setSequenceNumber | back to summary |
|---|---|
| public void setSequenceNumber(long number) Sets the packet sequence number of the global request represented by this future.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides org. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |
ReplyHandler is invoked asynchronously when the reply for a request with want-reply = true is
received. It is not invoked if the request could not be sent; to catch such cases
DefaultSshFuture#await(CancelOption[]) the GlobalRequestFuture and check
GlobalRequestFuture#getException().
| Modifier and Type | Method and Description |
|---|---|
| public void | accept(int
the command received, can be one of cmd, Buffer SshConstants#SSH_MSG_REQUEST_SUCCESS,
SshConstants#SSH_MSG_UNIMPLEMENTED, or SshConstants#SSH_MSG_REQUEST_FAILUREthe buffer)Buffer receivedInvoked by the framework upon reception of the reply. |
| accept | back to summary |
|---|---|
| public void accept(int cmd, Buffer buffer) Invoked by the framework upon reception of the reply. If the global request was sent with
| |