public class SSHSession extends SSHBase
Modifier and Type | Class and Description |
---|---|
class |
SSHSession.LocalTunnel |
static class |
SSHSession.NestedSequential
The class corresponding to the sequential nested element.
|
class |
SSHSession.RemoteTunnel |
description, location, project
Constructor and Description |
---|
SSHSession() |
Modifier and Type | Method and Description |
---|---|
void |
addTask(Task nestedTask)
Add a nested task to Sequential.
|
SSHSession.LocalTunnel |
createLocalTunnel() |
SSHSession.RemoteTunnel |
createRemoteTunnel() |
SSHSession.NestedSequential |
createSequential()
This is the sequential nested element of the macrodef.
|
void |
execute()
Establish the ssh session and execute all nestedTasks
|
void |
setLocaltunnels(java.lang.String tunnels)
Changes the comma-delimited list of local tunnels to establish
on the connection.
|
void |
setRemotetunnels(java.lang.String tunnels)
Changes the comma-delimited list of remote tunnels to establish
on the connection.
|
void |
setTimeout(long timeout)
The connection can be dropped after a specified number of
milliseconds.
|
getFailonerror, getHost, getPort, getServerAliveCountMax, getServerAliveIntervalSeconds, getUserInfo, getVerbose, init, openSession, setFailonerror, setHost, setKeyfile, setKnownhosts, setPassphrase, setPassword, setPort, setServerAliveCountMax, setServerAliveIntervalSeconds, setTrust, setUsername, setVerbose
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
log
public void addTask(Task nestedTask)
nestedTask
- Nested task to execute sequentiallypublic void setTimeout(long timeout)
timeout
- The new timeout value in secondspublic void setLocaltunnels(java.lang.String tunnels)
tunnels
- a comma-delimited list of lport:rhost:rport
tunnel specificationspublic void setRemotetunnels(java.lang.String tunnels)
tunnels
- a comma-delimited list of rport:lhost:lport
tunnel specificationspublic void execute() throws BuildException
execute
in class Task
BuildException
- if one of the nested tasks fails, or
network error or bad parameter.public SSHSession.LocalTunnel createLocalTunnel()
public SSHSession.RemoteTunnel createRemoteTunnel()
public SSHSession.NestedSequential createSequential()