public class DiscoveryRegistry extends java.lang.Object implements DiscoveryListener, DiscoveryAgent
Constructor and Description |
---|
DiscoveryRegistry() |
DiscoveryRegistry(DiscoveryAgent agent) |
Modifier and Type | Method and Description |
---|---|
void |
addDiscoveryAgent(DiscoveryAgent agent) |
void |
addDiscoveryListener(DiscoveryListener listener) |
java.util.Set<java.net.URI> |
getServices() |
void |
registerService(java.net.URI serviceUri)
register a service
|
void |
removeDiscoveryListener(DiscoveryListener listener) |
void |
reportFailed(java.net.URI serviceUri)
A process actively using a service may see it go down before the DiscoveryAgent notices the
service's failure.
|
void |
serviceAdded(java.net.URI service) |
void |
serviceRemoved(java.net.URI service) |
void |
setDiscoveryListener(DiscoveryListener listener)
Sets the discovery listener
|
void |
unregisterService(java.net.URI serviceUri)
register a service
|
public DiscoveryRegistry()
public DiscoveryRegistry(DiscoveryAgent agent)
public void addDiscoveryAgent(DiscoveryAgent agent)
public java.util.Set<java.net.URI> getServices()
public void registerService(java.net.URI serviceUri) throws java.io.IOException
DiscoveryAgent
registerService
in interface DiscoveryAgent
java.io.IOException
public void reportFailed(java.net.URI serviceUri) throws java.io.IOException
DiscoveryAgent
reportFailed
in interface DiscoveryAgent
java.io.IOException
public void unregisterService(java.net.URI serviceUri) throws java.io.IOException
DiscoveryAgent
unregisterService
in interface DiscoveryAgent
java.io.IOException
public void setDiscoveryListener(DiscoveryListener listener)
DiscoveryAgent
setDiscoveryListener
in interface DiscoveryAgent
public void addDiscoveryListener(DiscoveryListener listener)
public void removeDiscoveryListener(DiscoveryListener listener)
public void serviceAdded(java.net.URI service)
serviceAdded
in interface DiscoveryListener
public void serviceRemoved(java.net.URI service)
serviceRemoved
in interface DiscoveryListener