public class SocketFactory extends Object
Modifier | Constructor and Description |
---|---|
protected |
SocketFactory() |
Modifier and Type | Method and Description |
---|---|
Socket |
createSocket(InetAddress address,
int port) |
Socket |
createSocket(InetAddress address,
int port,
InetAddress localAddr,
int localPort) |
Socket |
createSocket(String host,
int port) |
Socket |
createSocket(String host,
int port,
InetAddress localAddr,
int localPort) |
static SocketFactory |
getDefault()
Returns the default instance of this class.
|
public static SocketFactory getDefault()
public Socket createSocket(String host, int port) throws IOException
IOException
public Socket createSocket(InetAddress address, int port) throws IOException
IOException
public Socket createSocket(String host, int port, InetAddress localAddr, int localPort) throws IOException
IOException
public Socket createSocket(InetAddress address, int port, InetAddress localAddr, int localPort) throws IOException
IOException
Copyright © 2016. All rights reserved.