com.mindbright.ssh
Class SSHSocketFactory

java.lang.Object
  |
  +--com.mindbright.ssh.SSHClientUserAdaptor
        |
        +--com.mindbright.ssh.SSHSocketFactory
All Implemented Interfaces:
SSHClientUser

public class SSHSocketFactory
extends SSHClientUserAdaptor


Field Summary
protected  SSHAuthenticator authenticator
           
protected  java.util.Hashtable clientCache
           
static int NOLISTENPORT
           
 
Fields inherited from class com.mindbright.ssh.SSHClientUserAdaptor
interactor, sshHost, sshPort
 
Constructor Summary
SSHSocketFactory(java.lang.String host, int port, SSHAuthenticator authenticator)
           
SSHSocketFactory(java.lang.String host, SSHAuthenticator authenticator)
           
 
Method Summary
protected  void addClient(SSHClient client)
           
 void alert(java.lang.String msg)
           
protected  void closePseudoAll(SSHClient client)
           
protected  void closePseudoUser(SSHClient client, SSHSocketImpl u)
           
 void connected(SSHClient client)
           
 SSHServerSocket createServerSocket(int port)
           
 SSHServerSocket createServerSocket(int port, int backlog)
           
 SSHSocket createSocket(java.lang.String address, int port)
           
protected  SSHSocketImpl createSocketImpl(SSHClient client, boolean acceptor)
           
protected  SSHClient createSSHClient(int listenPort)
           
 void disconnected(SSHClient client, boolean graceful)
           
protected  void finalize()
           
protected  SSHClient getClient()
           
 void open(SSHClient client)
           
protected  void registerPseudoUser(SSHClient client, SSHSocketImpl impl)
           
 void report(java.lang.String msg)
           
 void setAuthenticator(SSHAuthenticator authenticator)
           
 void setServer(java.lang.String host)
           
 void setServer(java.lang.String host, int port)
           
 
Methods inherited from class com.mindbright.ssh.SSHClientUserAdaptor
getAliveInterval, getCompressionLevel, getDisplay, getInteractor, getMaxPacketSz, getProxyConnection, getSrvHost, getSrvPort, wantPTY, wantX11Forward
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NOLISTENPORT

public static final int NOLISTENPORT
See Also:
Constant Field Values

authenticator

protected SSHAuthenticator authenticator

clientCache

protected java.util.Hashtable clientCache
Constructor Detail

SSHSocketFactory

public SSHSocketFactory(java.lang.String host,
                        int port,
                        SSHAuthenticator authenticator)

SSHSocketFactory

public SSHSocketFactory(java.lang.String host,
                        SSHAuthenticator authenticator)
Method Detail

getClient

protected SSHClient getClient()

finalize

protected void finalize()
                 throws java.io.IOException
Overrides:
finalize in class java.lang.Object
java.io.IOException

addClient

protected void addClient(SSHClient client)

registerPseudoUser

protected void registerPseudoUser(SSHClient client,
                                  SSHSocketImpl impl)

closePseudoAll

protected void closePseudoAll(SSHClient client)

closePseudoUser

protected void closePseudoUser(SSHClient client,
                               SSHSocketImpl u)

createSSHClient

protected SSHClient createSSHClient(int listenPort)
                             throws java.io.IOException
java.io.IOException

createSocketImpl

protected SSHSocketImpl createSocketImpl(SSHClient client,
                                         boolean acceptor)
                                  throws java.io.IOException
java.io.IOException

createSocket

public SSHSocket createSocket(java.lang.String address,
                              int port)
                       throws java.io.IOException
java.io.IOException

createServerSocket

public SSHServerSocket createServerSocket(int port,
                                          int backlog)
                                   throws java.io.IOException
java.io.IOException

createServerSocket

public SSHServerSocket createServerSocket(int port)
                                   throws java.io.IOException
java.io.IOException

setServer

public void setServer(java.lang.String host,
                      int port)

setServer

public void setServer(java.lang.String host)

setAuthenticator

public void setAuthenticator(SSHAuthenticator authenticator)

open

public void open(SSHClient client)

connected

public void connected(SSHClient client)

disconnected

public void disconnected(SSHClient client,
                         boolean graceful)

report

public void report(java.lang.String msg)

alert

public void alert(java.lang.String msg)