Package com.sshtools.client.tasks
Class AbstractSubsystemTask
java.lang.Object
com.sshtools.common.ssh.AbstractRequestFuture
com.sshtools.common.ssh.ConnectionAwareTask
com.sshtools.client.tasks.AbstractSubsystemTask
- All Implemented Interfaces:
com.sshtools.common.ssh.RequestFuture
,Runnable
public abstract class AbstractSubsystemTask
extends com.sshtools.common.ssh.ConnectionAwareTask
An abstract task for connecting to an SSH subsystem.
-
Field Summary
FieldsFields inherited from class com.sshtools.common.ssh.ConnectionAwareTask
con, lastError
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected SessionChannelNG
protected abstract void
doSubsystemTask
(SessionChannelNG session) protected void
doTask()
protected abstract int
protected abstract com.sshtools.common.util.UnsignedInteger32
protected abstract com.sshtools.common.util.UnsignedInteger32
protected SessionChannelNG
byte[]
protected void
onCloseSession
(SessionChannelNG session) void
sendMessage
(com.sshtools.common.ssh.Packet msg) Methods inherited from class com.sshtools.common.ssh.ConnectionAwareTask
getLastError, run
Methods inherited from class com.sshtools.common.ssh.AbstractRequestFuture
addFutureListener, done, isDone, isSuccess, waitFor, waitForever
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.sshtools.common.ssh.RequestFuture
isDoneAndSuccess
-
Field Details
-
timeout
protected long timeout
-
-
Constructor Details
-
AbstractSubsystemTask
public AbstractSubsystemTask(com.sshtools.common.ssh.SshConnection con)
-
-
Method Details
-
doTask
protected void doTask()- Specified by:
doTask
in classcom.sshtools.common.ssh.ConnectionAwareTask
-
createSession
- Throws:
com.sshtools.common.ssh.SshException
-
getMinimumWindowSize
protected abstract com.sshtools.common.util.UnsignedInteger32 getMinimumWindowSize() -
getMaximumWindowSize
protected abstract com.sshtools.common.util.UnsignedInteger32 getMaximumWindowSize() -
getMaximumPacketSize
protected abstract int getMaximumPacketSize() -
getSession
-
nextMessage
public byte[] nextMessage() throws com.sshtools.common.ssh.SshException- Throws:
com.sshtools.common.ssh.SshException
-
onCloseSession
-
doSubsystemTask
protected abstract void doSubsystemTask(SessionChannelNG session) throws com.sshtools.common.ssh.SshException - Throws:
com.sshtools.common.ssh.SshException
-
sendMessage
public void sendMessage(com.sshtools.common.ssh.Packet msg) throws com.sshtools.common.ssh.SshException - Throws:
com.sshtools.common.ssh.SshException
-