Class ExitStatusChannelRequestHandler
- java.lang.Object
-
- org.apache.sshd.common.util.logging.AbstractLoggingBean
-
- org.apache.sshd.common.channel.AbstractRequestHandler<Channel>
-
- org.apache.sshd.common.channel.AbstractChannelRequestHandler
-
- org.apache.sshd.client.channel.exit.AbstractChannelExitRequestHandler<java.lang.Integer>
-
- org.apache.sshd.client.channel.exit.ExitStatusChannelRequestHandler
-
- All Implemented Interfaces:
ChannelRequestHandler,RequestHandler<Channel>,NamedResource
public class ExitStatusChannelRequestHandler extends AbstractChannelExitRequestHandler<java.lang.Integer>
- See Also:
- RFC4254 section 6.10
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.sshd.common.channel.RequestHandler
RequestHandler.Result
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringNAME-
Fields inherited from class org.apache.sshd.client.channel.exit.AbstractChannelExitRequestHandler
holder, notifier
-
Fields inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
log
-
Fields inherited from interface org.apache.sshd.common.channel.ChannelRequestHandler
CHANN2HNDLR
-
Fields inherited from interface org.apache.sshd.common.NamedResource
BY_NAME_COMPARATOR, NAME_EXTRACTOR
-
-
Constructor Summary
Constructors Constructor Description ExitStatusChannelRequestHandler(java.util.concurrent.atomic.AtomicReference<java.lang.Integer> holder, EventNotifier<? super java.lang.String> notifier)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetName()protected java.lang.IntegerprocessRequestValue(Channel channel, int exitStatus)protected java.lang.IntegerprocessRequestValue(Channel channel, java.lang.String request, Buffer buffer)Invoked by default fromAbstractChannelExitRequestHandler.process(Channel, String, boolean, Buffer)when a request matching the handler's name is received-
Methods inherited from class org.apache.sshd.client.channel.exit.AbstractChannelExitRequestHandler
getEvent, notifyStateChanged, process
-
-
-
-
Field Detail
-
NAME
public static final java.lang.String NAME
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ExitStatusChannelRequestHandler
public ExitStatusChannelRequestHandler(java.util.concurrent.atomic.AtomicReference<java.lang.Integer> holder, EventNotifier<? super java.lang.String> notifier)
-
-
Method Detail
-
getName
public final java.lang.String getName()
- Returns:
- The resource name
-
processRequestValue
protected java.lang.Integer processRequestValue(Channel channel, java.lang.String request, Buffer buffer) throws java.lang.Exception
Description copied from class:AbstractChannelExitRequestHandlerInvoked by default fromAbstractChannelExitRequestHandler.process(Channel, String, boolean, Buffer)when a request matching the handler's name is received- Specified by:
processRequestValuein classAbstractChannelExitRequestHandler<java.lang.Integer>- Parameters:
channel- TheChannelthrough which the request was receivedrequest- The received request - Note: guaranteed to match the handler's name if invoked fromAbstractChannelExitRequestHandler.process(Channel, String, boolean, Buffer)buffer- The receivedBufferfor extracting the data- Returns:
- The extracted data - if
nullthen request is ignored andUnsupportedis returned - Throws:
java.lang.Exception- If failed to process the received request buffer
-
processRequestValue
protected java.lang.Integer processRequestValue(Channel channel, int exitStatus) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-