public class Connection extends Object
| Modifier and Type | Field and Description |
|---|---|
InputStream |
in |
ConnectionManager |
mgr |
OutputStream |
out |
Socket |
socket |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
boolean |
isClosed() |
boolean |
isSame(InetAddress host,
int port) |
static Connection |
open(InetAddress host,
int port,
String localHost,
SSLContext sslContext) |
static Connection |
open(InetAddress host,
int port,
String localHost,
SSLContext sslContext,
ConnectionManager mgr) |
void |
release()
See
ConnectionManager for documentation. |
public final ConnectionManager mgr
public Socket socket
public InputStream in
public OutputStream out
public static Connection open(InetAddress host, int port, String localHost, SSLContext sslContext) throws UnknownHostException, IOException
UnknownHostExceptionIOExceptionpublic static Connection open(InetAddress host, int port, String localHost, SSLContext sslContext, ConnectionManager mgr) throws UnknownHostException, IOException
UnknownHostExceptionIOExceptionpublic boolean isSame(InetAddress host, int port)
public void close()
throws IOException
IOExceptionpublic boolean isClosed()
public void release()
throws IOException
ConnectionManager for documentation.IOExceptionCopyright © 2012. All Rights Reserved.