edu.UCL.satin.impl.arch.components.comms
Class Discovery

java.lang.Object
  extended byedu.UCL.satin.arch.components.Component
      extended byedu.UCL.satin.impl.arch.components.comms.Discovery
All Implemented Interfaces:
ComponentFacet, DiscoveryFacet, Facet
Direct Known Subclasses:
CentralDiscovery

public abstract class Discovery
extends Component
implements DiscoveryFacet

Represents a SATIN discovery component

Author:
Stefanos Zachariadis

Field Summary
 
Fields inherited from class edu.UCL.satin.arch.components.Component
immutable, properties
 
Fields inherited from interface edu.UCL.satin.arch.facets.ComponentFacet
DISABLED, ENABLED
 
Constructor Summary
Discovery(java.lang.Object id)
          Creates a new Discovery component with the given component identifier
 
Method Summary
abstract  void addListener(ComponentListener c)
          Adds a listener that will be notified when any new component is discovered.
abstract  void addListener(ComponentListener c, java.util.Hashtable filter)
          Adds a listener that will be notified when any new component matching the filter given is discovered.
abstract  Component[] getComponents(java.util.Hashtable properties)
          Returns an array of Components found that match the given property set
abstract  void removeListener(ComponentListener c)
          Removes all instances of the given listener (including any different filters) from the list of listeners to be notified.
abstract  void removeListener(ComponentListener c, java.util.Hashtable filter)
          Removes the particular listener+filter pair from the list of listeners to be notified.
 
Methods inherited from class edu.UCL.satin.arch.components.Component
addAttribute, construct, destroy, getAttribute, getProperties, hasAttribute, isEnabled, match, setEnabled, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Discovery

public Discovery(java.lang.Object id)
Creates a new Discovery component with the given component identifier

Parameters:
id - The component identifier
Method Detail

addListener

public abstract void addListener(ComponentListener c)
Adds a listener that will be notified when any new component is discovered.

Specified by:
addListener in interface DiscoveryFacet
Parameters:
c - the listener that will be notified

addListener

public abstract void addListener(ComponentListener c,
                                 java.util.Hashtable filter)
Adds a listener that will be notified when any new component matching the filter given is discovered.

Specified by:
addListener in interface DiscoveryFacet
Parameters:
c - the listener to be notified
filter - The filter, as a hashtable of attributes

removeListener

public abstract void removeListener(ComponentListener c)
Removes all instances of the given listener (including any different filters) from the list of listeners to be notified.

Specified by:
removeListener in interface DiscoveryFacet
Parameters:
c - The listener to be removed.

removeListener

public abstract void removeListener(ComponentListener c,
                                    java.util.Hashtable filter)
Removes the particular listener+filter pair from the list of listeners to be notified.

Specified by:
removeListener in interface DiscoveryFacet
Parameters:
c - The listener to be removed
filter - The filter matches of which this listener will not be notified any more.

getComponents

public abstract Component[] getComponents(java.util.Hashtable properties)
Returns an array of Components found that match the given property set

Specified by:
getComponents in interface DiscoveryFacet
Parameters:
properties - The properties that the returned components need to match
Returns:
The components that match the given properties