APIdia Launch Partner
Top Constructors Methods
javax.net

pack-priv Class DefaultSocketFactory

Located in compilation unit of javax.net.SocketFactory.

extends SocketFactory
Class Inheritance

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public Socket
createSocket()

Overrides javax.net.SocketFactory.createSocket.

Creates an unconnected socket.

public Socket
createSocket(String host, int port)

Implements abstract javax.net.SocketFactory.createSocket.

Creates a socket and connects it to the specified remote host at the specified remote port.

public Socket
createSocket(InetAddress address, int port)

Implements abstract javax.net.SocketFactory.createSocket.

Creates a socket and connects it to the specified port number at the specified address.

public Socket
createSocket(String host, int port, InetAddress clientAddress, int clientPort)

Implements abstract javax.net.SocketFactory.createSocket.

Creates a socket and connects it to the specified remote host on the specified remote port.

public Socket
createSocket(InetAddress address, int port, InetAddress clientAddress, int clientPort)

Implements abstract javax.net.SocketFactory.createSocket.

Creates a socket and connect it to the specified remote address on the specified remote port.

Inherited from javax.net.SocketFactory:
getDefault

Constructor Detail

DefaultSocketFactoryback to summary
pack-priv DefaultSocketFactory()

Method Detail

createSocketback to summary
public Socket createSocket()

Overrides javax.net.SocketFactory.createSocket.

Doc from javax.net.SocketFactory.createSocket.

Creates an unconnected socket.

createSocketback to summary
public Socket createSocket(String host, int port) throws IOException, UnknownHostException

Implements abstract javax.net.SocketFactory.createSocket.

Doc from javax.net.SocketFactory.createSocket.

Creates a socket and connects it to the specified remote host at the specified remote port. This socket is configured using the socket options established for this factory.

Exceptions
IOException:
if an I/O error occurs when creating the socket
UnknownHostException:
if the host is not known
createSocketback to summary
public Socket createSocket(InetAddress address, int port) throws IOException

Implements abstract javax.net.SocketFactory.createSocket.

Doc from javax.net.SocketFactory.createSocket.

Creates a socket and connects it to the specified port number at the specified address. This socket is configured using the socket options established for this factory.

Exceptions
IOException:
if an I/O error occurs when creating the socket
createSocketback to summary
public Socket createSocket(String host, int port, InetAddress clientAddress, int clientPort) throws IOException, UnknownHostException

Implements abstract javax.net.SocketFactory.createSocket.

Doc from javax.net.SocketFactory.createSocket.

Creates a socket and connects it to the specified remote host on the specified remote port. The socket will also be bound to the local address and port supplied. This socket is configured using the socket options established for this factory.

Exceptions
IOException:
if an I/O error occurs when creating the socket
UnknownHostException:
if the host is not known
createSocketback to summary
public Socket createSocket(InetAddress address, int port, InetAddress clientAddress, int clientPort) throws IOException

Implements abstract javax.net.SocketFactory.createSocket.

Doc from javax.net.SocketFactory.createSocket.

Creates a socket and connect it to the specified remote address on the specified remote port. The socket will also be bound to the local address and port supplied. The socket is configured using the socket options established for this factory.

Exceptions
IOException:
if an I/O error occurs when creating the socket