public class StandardSocketFactory extends Object implements SocketFactory
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_ACCEPTED_SOCKET_TIMEOUT
Default value for
getAcceptedSocketTimeout() |
Constructor and Description |
---|
StandardSocketFactory() |
Modifier and Type | Method and Description |
---|---|
void |
configureNewAcceptedSocket(Socket theSocket)
Invoked by server processes each time a new server is
accepted
in order to set configuration settings on the new socket |
ServerSocket |
createServerSocket()
Create a standard server socket
|
Socket |
createSocket()
Create a standard client socket
|
ServerSocket |
createTlsServerSocket()
Create a TLS server socket
|
Socket |
createTlsSocket()
Create a TLS client socket
|
int |
getAcceptedSocketTimeout()
Gets the value for
Socket.setSoTimeout(int) to be set on newly accepted sockets in server applications. |
void |
setAcceptedSocketTimeout(int theAcceptedSocketTimeout)
Sets the value for
Socket.setSoTimeout(int) to be set on newly accepted sockets in server applications |
public static final int DEFAULT_ACCEPTED_SOCKET_TIMEOUT
getAcceptedSocketTimeout()
public StandardSocketFactory()
public int getAcceptedSocketTimeout()
Socket.setSoTimeout(int)
to be set on newly accepted sockets in server applications. Default is DEFAULT_ACCEPTED_SOCKET_TIMEOUT
public void setAcceptedSocketTimeout(int theAcceptedSocketTimeout)
Socket.setSoTimeout(int)
to be set on newly accepted sockets in server applicationspublic Socket createSocket() throws IOException
createSocket
in interface SocketFactory
IOException
public Socket createTlsSocket() throws IOException
createTlsSocket
in interface SocketFactory
IOException
public ServerSocket createServerSocket() throws IOException
createServerSocket
in interface SocketFactory
IOException
public ServerSocket createTlsServerSocket() throws IOException
createTlsServerSocket
in interface SocketFactory
IOException
public void configureNewAcceptedSocket(Socket theSocket) throws SocketException
SocketFactory
accepted
in order to set configuration settings on the new socketconfigureNewAcceptedSocket
in interface SocketFactory
SocketException
Copyright © 2001–2017 University Health Network. All rights reserved.