Package com.tangosol.net
Class TcpDatagramSocketProvider
java.lang.Object
com.tangosol.net.TcpDatagramSocketProvider
- All Implemented Interfaces:
DatagramSocketProvider
TcpDatagramSocketProvider produces datagram sockets that uses
TCP sockets underneath for unicast communication. For multicast, it still uses
the MulticastSockets.
- Since:
- Coherence 12.1.2
- Author:
- bb 2011.11.21
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
DefaultDependenceis is a basic implementation of the Dependencies interface providing "setter" methods for each property.static interface
Dependencies specifies all dependency requirements of the TcpDatagramSocketProvider. -
Field Summary
Modifier and TypeFieldDescriptionstatic final TcpDatagramSocketProvider
A default SocketProvider instance.protected TcpDatagramSocketProvider.Dependencies
TcpDatagramSocketProvider Dependencies -
Constructor Summary
ConstructorDescriptionConstruct a TcpDatagramSocketProvider.Construct a TcpDatagramSocketProvider -
Method Summary
Modifier and TypeMethodDescriptionprotected TcpDatagramSocket
configure
(TcpDatagramSocket socket) Configure the socket.boolean
isSecure()
Return true iff the provider returns sockets which are secured, for instance by TLS.Return a new DatagramSocket.Return a new MulticastSocket.toString()
-
Field Details
-
INSTANCE
A default SocketProvider instance. -
m_dependencies
TcpDatagramSocketProvider Dependencies
-
-
Constructor Details
-
TcpDatagramSocketProvider
public TcpDatagramSocketProvider()Construct a TcpDatagramSocketProvider. -
TcpDatagramSocketProvider
Construct a TcpDatagramSocketProvider- Parameters:
deps
- the provider dependencies, or null
-
-
Method Details
-
openDatagramSocket
Return a new DatagramSocket.- Specified by:
openDatagramSocket
in interfaceDatagramSocketProvider
- Returns:
- the DatagramSocket
- Throws:
IOException
- if an I/O related error occurs
-
openMulticastSocket
Return a new MulticastSocket.- Specified by:
openMulticastSocket
in interfaceDatagramSocketProvider
- Returns:
- the MulticastSocket
- Throws:
IOException
- if an I/O related error occurs
-
isSecure
public boolean isSecure()Return true iff the provider returns sockets which are secured, for instance by TLS.- Specified by:
isSecure
in interfaceDatagramSocketProvider
- Returns:
- true iff the provider returns secured sockets
-
toString
-
configure
Configure the socket.- Parameters:
socket
- the socket- Returns:
- the configured socket
-