Interface ILcdGXYLayerSubsetList

All Known Implementing Classes:
TLcdGXYLayerSubsetList

public interface ILcdGXYLayerSubsetList
A layer subset list defines a set of domain objects that are present in one or more layers. It is structured as a list of layer subsets.

Individual domain objects can be added or removed. The set of domain objects can be retrieved for a given layer or for all layers.

You can iterate over this list by enumerating over the layers first, and then enumerating over the subset:


   Enumeration layers = list.layers();
   while (layers.hasMoreElements() ) {
     ILcdGXYLayer layer = (ILcdGXYLayer) layers.nextElement();
     Enumeration objects = list.layerSubset( layer );
     while (objects.hasMoreElements()) {
       Object object = objects.nextElement();
     }
   }
 
See Also:
  • Method Details

    • addElement

      void addElement(Object aObject, ILcdGXYLayer aGXYLayer)
      Adds a domain object that is part of the given layer.
      Parameters:
      aObject - the Object to add.
      aGXYLayer - the ILcdGXYLayer the Object belongs to.
    • removeElement

      void removeElement(Object aObject, ILcdGXYLayer aGXYLayer)
      Removes the domain object part of the given layer.
      Parameters:
      aObject - the Object to remove.
      aGXYLayer - the ILcdGXYLayer the Object belongs to.
    • layerSubset

      Enumeration layerSubset(ILcdGXYLayer aGXYLayer)
      Returns an Enumeration of all objects that are part of the given layer.
      Parameters:
      aGXYLayer - the layer whose objects to return
      Returns:
      an Enumeration of all objects that are part of the given layer.
    • layers

      Enumeration layers()
      Returns an Enumeration of all layers for which objects are present.
      Returns:
      an Enumeration of all objects that are part of the given layer.
    • retrieveGXYLayer

      ILcdGXYLayer retrieveGXYLayer(Object aObject)
      Returns the ILcdGXYLayer for which the given Object was added.
      Returns:
      the ILcdGXYLayer if aObject has been added, or null if aObject does not belong to this ILcdGXYLayerSubsetList
      See Also:
    • asAssocs

      ILcdAssoc[] asAssocs()
      Retrieves all the subsets as an array of ILcdAssoc. Each association in this array maps an ILcdGXYLayer to a Vector of domain objects.
      Returns:
      an array of ILcdAssoc objects, with the key being an ILcdGXYLayer, and the value a Vector.
    • removeAllElements

      void removeAllElements()
      Removes all the subsets.
    • elements

      Enumeration elements()
      Returns an Enumeration of all the Objects in all the ILcdGXYLayer subsets.
      Returns:
      an Enumeration of all the Objects in all the ILcdGXYLayer subsets
    • size

      int size()
      Returns the number of all the Objects in all the ILcdGXYLayer subsets.
      Returns:
      the number of all the Objects in all the ILcdGXYLayer subsets
    • contains

      boolean contains(Object aObject)
      Returns whether the given object is contained in this subset list.
      Returns:
      true if the given Object belongs to one of the ILcdGXYLayer subsets. Tests shall be done by comparing Object reference (not using Object.equals)