public interface ConnectionManager
| Modifier and Type | Method and Description |
|---|---|
void |
addConnectionOpenListener(P2PConnectionOpenListener listener)
Adds a listener instance will be notified when a new point-to-point connection
has been opened.
|
P2PConnection[] |
getConnections()
Returns all active connections managed by this ConnectionManager instance.
|
P2PConnection |
openConnection(java.lang.String url)
Returns the point-to-point connection between the current host and the host specified by the
supplied url.
|
void |
removeConnectionOpenListener(P2PConnectionOpenListener listener)
Removes the supplied listener instance from the list of registered listeners.
|
void |
setNetService(java.lang.String netServiceName,
ServiceConnectionAcceptor acceptor)
Registers a Net service with a given name and associated with this net service
connection acceptor.
|
void setNetService(java.lang.String netServiceName,
ServiceConnectionAcceptor acceptor)
netServiceName - the identifier of the Net serviceacceptor - Net service specific instance which will handle connection request
in the scope of this Net service.P2PConnection openConnection(java.lang.String url) throws java.io.IOException
url - the URL of the remote host.java.io.IOException - if the connection does not exist and cannot be established.P2PConnection[] getConnections()
void addConnectionOpenListener(P2PConnectionOpenListener listener)
openConnection(String url)
or if a remote host has been initiated the connection to this host. The listener will
be notified in both cases.listener - the listener instancevoid removeConnectionOpenListener(P2PConnectionOpenListener listener)
listener - the listener instance being removed.Copyright © 2019 Bosch Software Innovations GmbH. All Rights Reserved.