Package org.apache.ofbiz.base.util
Class RMIExtendedSocketFactory
java.lang.Object
java.rmi.server.RMISocketFactory
org.apache.ofbiz.base.util.RMIExtendedSocketFactory
- All Implemented Interfaces:
RMIClientSocketFactory
,RMIServerSocketFactory
A
RMISocketFactory
implementation that creates ServerSocket
s bound
on a specified network interface.-
Constructor Summary
ConstructorDescriptionDefault constructor.RMIExtendedSocketFactory
(String hostIpAddress) Creates a newRMIExtendedSocketFactory
which will createServerSocket
s bound on the specified network interface.RMIExtendedSocketFactory
(InetAddress inetAddress) Creates a newRMIExtendedSocketFactory
which will createServerSocket
s bound on the specified network interface. -
Method Summary
Modifier and TypeMethodDescriptioncreateServerSocket
(int port) createSocket
(String host, int port) Methods inherited from class java.rmi.server.RMISocketFactory
getDefaultSocketFactory, getFailureHandler, getSocketFactory, setFailureHandler, setSocketFactory
-
Constructor Details
-
RMIExtendedSocketFactory
public RMIExtendedSocketFactory()Default constructor. Bind the server sockets on all interfaces. -
RMIExtendedSocketFactory
Creates a newRMIExtendedSocketFactory
which will createServerSocket
s bound on the specified network interface.- Parameters:
inetAddress
- TheInetAddress
of the network interface.
-
RMIExtendedSocketFactory
Creates a newRMIExtendedSocketFactory
which will createServerSocket
s bound on the specified network interface.- Parameters:
hostIpAddress
- The IP address of the interface to bind the server sockets to.- Throws:
UnknownHostException
- If an invalid IP address is provided.
-
-
Method Details
-
createServerSocket
- Specified by:
createServerSocket
in interfaceRMIServerSocketFactory
- Specified by:
createServerSocket
in classRMISocketFactory
- Throws:
IOException
-
createSocket
- Specified by:
createSocket
in interfaceRMIClientSocketFactory
- Specified by:
createSocket
in classRMISocketFactory
- Throws:
IOException
-