com.sshtools.net
Class SocketTransport
java.lang.Object
java.net.Socket
com.sshtools.net.SocketTransport
- All Implemented Interfaces:
- SocketTimeoutSupport, SshIO, SshTransport
public class SocketTransport
- extends Socket
- implements SshTransport, SocketTimeoutSupport
Extends a Socket to provide an SshTransport suitable for use
in making connections using the SshConnector.
- Author:
- Lee David Painter
| Methods inherited from class java.net.Socket |
bind, close, connect, connect, getChannel, getInetAddress, getInputStream, getKeepAlive, getLocalAddress, getLocalPort, getLocalSocketAddress, getOOBInline, getOutputStream, getPort, getReceiveBufferSize, getRemoteSocketAddress, getReuseAddress, getSendBufferSize, getSoLinger, getSoTimeout, getTcpNoDelay, getTrafficClass, isBound, isClosed, isConnected, isInputShutdown, isOutputShutdown, sendUrgentData, setKeepAlive, setOOBInline, setPerformancePreferences, setReceiveBufferSize, setReuseAddress, setSendBufferSize, setSocketImplFactory, setSoLinger, setSoTimeout, setTcpNoDelay, setTrafficClass, shutdownInput, shutdownOutput, toString |
SocketTransport
public SocketTransport(String hostname,
int port)
throws IOException
- Connect the socket.
- Parameters:
hostname - port -
- Throws:
IOException
getHost
public String getHost()
- Get the hostname of the connected host.
- Specified by:
getHost in interface SshTransport
duplicate
public SshTransport duplicate()
throws IOException
- Specified by:
duplicate in interface SshTransport
- Throws:
IOException
Copyright © 2012. All Rights Reserved.