com.jcraft.jsch

Class Session

Implemented Interfaces:
Runnable

public class Session
extends java.lang.Object
implements Runnable

Method Summary

void
connect()
void
connect(int connectTimeout)
void
delPortForwardingL(int lport)
void
delPortForwardingR(int rport)
void
disconnect()
void
encode(Packet packet)
String
getClientVersion()
String
getConfig(String name)
HostKey
getHostKey()
String[]
getPortForwardingL()
String
getServerVersion()
int
getTimeout()
boolean
isConnected()
Channel
openChannel(String type)
Buffer
read(Buffer buf)
void
rekey()
void
run()
void
setClientVersion(String cv)
void
setConfig(java.util.Hashtable foo)
void
setConfig(java.util.Properties foo)
void
setHost(String host)
void
setInputStream(InputStream in)
void
setOutputStream(OutputStream out)
void
setPassword(String foo)
void
setPort(int port)
void
setPortForwardingL(String boundaddress, int lport, String host, int rport)
void
setPortForwardingL(int lport, String host, int rport)
void
setPortForwardingR(int rport, String host, int lport)
void
setProxy(Proxy proxy)
void
setSocketFactory(SocketFactory foo)
void
setTimeout(int foo)
void
setUserInfo(UserInfo userinfo)
void
setX11Cookie(String cookie)
void
setX11Host(String host)
void
setX11Port(int port)
void
write(Packet packet)
void
write(Packet packet, Channel c, int length)

Method Details

connect

public void connect()
            throws JSchException

connect

public void connect(int connectTimeout)
            throws JSchException

delPortForwardingL

public void delPortForwardingL(int lport)
            throws JSchException

delPortForwardingR

public void delPortForwardingR(int rport)
            throws JSchException

disconnect

public void disconnect()

encode

public void encode(Packet packet)
            throws Exception

getClientVersion

public String getClientVersion()

getConfig

public String getConfig(String name)

getHostKey

public HostKey getHostKey()

getPortForwardingL

public String[] getPortForwardingL()
            throws JSchException

getServerVersion

public String getServerVersion()

getTimeout

public int getTimeout()

isConnected

public boolean isConnected()

openChannel

public Channel openChannel(String type)
            throws JSchException

read

public Buffer read(Buffer buf)
            throws Exception

rekey

public void rekey()
            throws Exception

run

public void run()

setClientVersion

public void setClientVersion(String cv)

setConfig

public void setConfig(java.util.Hashtable foo)

setConfig

public void setConfig(java.util.Properties foo)

setHost

public void setHost(String host)

setInputStream

public void setInputStream(InputStream in)

setOutputStream

public void setOutputStream(OutputStream out)

setPassword

public void setPassword(String foo)

setPort

public void setPort(int port)

setPortForwardingL

public void setPortForwardingL(String boundaddress,
                               int lport,
                               String host,
                               int rport)
            throws JSchException

setPortForwardingL

public void setPortForwardingL(int lport,
                               String host,
                               int rport)
            throws JSchException

setPortForwardingR

public void setPortForwardingR(int rport,
                               String host,
                               int lport)
            throws JSchException

setProxy

public void setProxy(Proxy proxy)

setSocketFactory

public void setSocketFactory(SocketFactory foo)

setTimeout

public void setTimeout(int foo)
            throws JSchException

setUserInfo

public void setUserInfo(UserInfo userinfo)

setX11Cookie

public void setX11Cookie(String cookie)

setX11Host

public void setX11Host(String host)

setX11Port

public void setX11Port(int port)

write

public void write(Packet packet)
            throws Exception

write

public void write(Packet packet,
                  Channel c,
                  int length)
            throws Exception