org.openorb.orb.net
Interface SocketFactory
- All Known Implementing Classes:
- ConfiguredSocketFactory
- public interface SocketFactory
An abstraction for creating sockets.
- Version:
- $Revision: 1.2 $ $Date: 2003/10/29 14:50:08 $
- Author:
- Richard G Clark
Method Summary |
java.net.ServerSocket |
createServerSocket(java.net.InetAddress host,
int port)
Creates a new socket listening to the specified host and port. |
java.net.Socket |
createSocket(java.net.InetAddress host,
int port)
Creates a new socket to the specified host and port. |
createSocket
public java.net.Socket createSocket(java.net.InetAddress host,
int port)
throws java.io.IOException
- Creates a new socket to the specified host and port.
- Parameters:
host
- the remote hostport
- the remote port- Returns:
- a configured
Socket
instance. - Throws:
java.io.IOException
- if an I/O error occurs when creating the socket.
createServerSocket
public java.net.ServerSocket createServerSocket(java.net.InetAddress host,
int port)
throws java.io.IOException
- Creates a new socket listening to the specified host and port.
- Parameters:
host
- the local hostport
- the local port- Returns:
- a configured
ServerSocket
instance. - Throws:
java.io.IOException
- if an I/O error occurs when creating the socket.