|
Platform SDK Java 8.5 API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.genesyslab.platform.commons.connection.ConnectionManager
public final class ConnectionManager
Factory for connections.
You can change connection implementation by setting system property 'com.genesyslab.platform.commons.connection.factory.class
' to fully
qualified name of the connection factory implementation.
Currently there is only one implementation - JBoss Netty framework.
Field Summary | |
---|---|
static java.lang.String |
CONN_FACTORY_KEY
Deprecated. |
Method Summary | |
---|---|
static ConnectionAcceptor |
createAcceptor(java.net.SocketAddress address,
ConnectionListener listener,
ConnectionContext ctx)
Creates connection acceptor object for the specified address. |
static ConnectionAcceptor |
createAcceptor(java.lang.String host,
int port,
ConnectionListener listener,
ConnectionContext ctx)
Creates connection acceptor object for the specified address. |
static Connection |
createConnection(java.net.InetAddress address,
int port,
ConnectionContext ctx)
Creates connection object for the specified server. |
static Connection |
createConnection(java.lang.String host,
int port,
ConnectionContext ctx)
Creates connection object for the specified server. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
@Deprecated public static final java.lang.String CONN_FACTORY_KEY
PsdkCustomization
,
PsdkCustomization.PsdkOption#PsdkConnectionFactory
,
Constant Field ValuesMethod Detail |
---|
public static Connection createConnection(java.lang.String host, int port, ConnectionContext ctx)
open
method to establish network connection.
host
- host to connect toport
- port to connect toctx
- context of connection
public static Connection createConnection(java.net.InetAddress address, int port, ConnectionContext ctx)
open
method to establish network connection.
address
- host to connect toport
- port to connect toctx
- context of connection
public static ConnectionAcceptor createAcceptor(java.lang.String host, int port, ConnectionListener listener, ConnectionContext ctx)
startAccepting
method to bind a socket.
host
- host to listenport
- port to listen onlistener
- a listener to notify about new connections
public static ConnectionAcceptor createAcceptor(java.net.SocketAddress address, ConnectionListener listener, ConnectionContext ctx)
startAccepting
method to bind a socket.
address
- address to listenlistener
- a listener to notify about new connections
|
Platform SDK Java 8.5 API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |