public final class NetworkConnectionServiceImpl extends Object implements NetworkConnectionService
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes all resources and unregisters all registered connection factories.
|
<T> ConnectionFactory<T> |
getConnectionFactory(Identifier connFactoryId)
Gets a ConnectionFactory.
|
<T> ConnectionFactory<T> |
registerConnectionFactory(Identifier connectionFactoryId,
Codec<T> codec,
EventHandler<Message<T>> eventHandler,
LinkListener<Message<T>> linkListener,
Identifier localEndPointId)
Registers an instance of ConnectionFactory corresponding to the connectionFactoryId.
|
void |
unregisterConnectionFactory(Identifier connFactoryId)
Unregisters a connectionFactory corresponding to the connectionFactoryId
and removes the localEndPointID of the connection factory from NameServer.
|
public <T> ConnectionFactory<T> registerConnectionFactory(Identifier connectionFactoryId, Codec<T> codec, EventHandler<Message<T>> eventHandler, LinkListener<Message<T>> linkListener, Identifier localEndPointId)
NetworkConnectionServiceregisterConnectionFactory in interface NetworkConnectionServiceconnectionFactoryId - a connection factory idcodec - a codec for type TeventHandler - an event handler for type TlinkListener - a link listenerlocalEndPointId - a local end point idpublic void unregisterConnectionFactory(Identifier connFactoryId)
NetworkConnectionServiceunregisterConnectionFactory in interface NetworkConnectionServiceconnFactoryId - a connection factory idpublic <T> ConnectionFactory<T> getConnectionFactory(Identifier connFactoryId)
getConnectionFactory in interface NetworkConnectionServiceconnFactoryId - the identifier of the ConnectionFactorypublic void close() throws Exception
NetworkConnectionServiceclose in interface AutoCloseableclose in interface NetworkConnectionServiceException - if this resource cannot be closedCopyright © 2017 The Apache Software Foundation. All rights reserved.