public class SocketConnection extends Connection
| Constructor and Description |
|---|
SocketConnection(IntradocClientConfig config) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close this socket connection
|
void |
connect()
Connect this socket to the configured destination
|
protected Socket |
createSocket()
Create the socket to the configured host
|
IntradocClientConfig |
getConfig() |
InputStream |
getInputStream()
Get a input stream for this connection
|
OutputStream |
getOutputStream()
Get a output stream for this connection
|
Socket |
getSocket() |
boolean |
isConnected() |
resetpublic SocketConnection(IntradocClientConfig config)
public IntradocClientConfig getConfig()
public void connect()
throws ProtocolException
connect in class ConnectionProtocolException - if an error occurspublic void close()
close in class Connectionpublic InputStream getInputStream() throws IOException
ConnectiongetInputStream in class ConnectionIOExceptionpublic OutputStream getOutputStream() throws IOException
ConnectiongetOutputStream in class ConnectionIOExceptionpublic boolean isConnected()
isConnected in class Connectionpublic Socket getSocket()
protected Socket createSocket() throws ProtocolException, IOException
IOExceptionProtocolException