Package com.luciad.lucy.map
Interface ILcyLayerSubsetList
- All Known Implementing Classes:
TLcyLayerSubsetList
public interface ILcyLayerSubsetList
This is an interface for defining a list of one or more
ILcdLayer
subset(s). This can be seen as a list of Vectors. Each Vector is
associated to an ILcdLayer. It contains a subset of Objects of the
ILcdModel the ILcdLayer refers to. The method asAssocs
returns and array of ILcdAssoc. The key of the ILcdAssoc refers to the
ILcdLayer, the value to the Vector.-
Method Summary
Modifier and TypeMethodDescriptionvoidaddElement(Object aObject, ILcdLayer aLayer) Adds anObjectto the subset associated with the givenILcdLayer.asAssocs()Retrieves all the subsets as an array ofILcdAssoc.booleanChecks ifaObjectis contained in one of the layer subsets of this list.elements()Returns anEnumerationof all the Objects in all theILcdLayersubsets.layers()Returns anEnumerationof allILcdLayers in this list which are associated with at least oneObject.layerSubset(ILcdLayer aLayer) Returns anEnumerationof all Objects currently in the subset associated with the givenILcdLayervoidRemoves all the subsets.voidremoveElement(Object aObject, ILcdLayer aLayer) Removes anObjectthat was in the subset associated with the givenILcdLayer.retrieveLayer(Object aObject) Returns the firstILcdLayerencountered in this list that is associated with the givenObject.intsize()Returns the number of Objects in all theILcdLayersubsets.
-
Method Details
-
addElement
Adds anObjectto the subset associated with the givenILcdLayer.aObjectmust belong to theILcdModelthat aLayer refers to.- Parameters:
aObject- TheObjectto add.aLayer- TheILcdLayeraObjectbelongs to.
-
removeElement
Removes anObjectthat was in the subset associated with the givenILcdLayer.- Parameters:
aObject- TheObjectto remove.aLayer- TheILcdLayeraObjectbelongs to.
-
layerSubset
Returns anEnumerationof all Objects currently in the subset associated with the givenILcdLayer- Returns:
- An
Enumerationof all Objects currently in the subset associated with the givenILcdLayer.
-
layers
Enumeration layers()Returns anEnumerationof allILcdLayers in this list which are associated with at least oneObject.- Returns:
- An
Enumerationof allILcdLayers in this list which are associated with at least oneObject.
-
retrieveLayer
Returns the firstILcdLayerencountered in this list that is associated with the givenObject. ReturnsnullifaObjectis not associated with anyILcdLayerin this list.- Parameters:
aObject- The object for which the layer should be retrieved.- Returns:
- The first
ILcdLayerassociated withaObject.
-
asAssocs
ILcdAssoc[] asAssocs()Retrieves all the subsets as an array ofILcdAssoc. The key of theILcdAssocrefers to anILcdLayer, the value to aVectorthat contains the subset of Objects that belongs to theILcdLayer.- Returns:
- The array of
ILcdAssocobjects associating the layers with their objects.
-
removeAllElements
void removeAllElements()Removes all the subsets. -
elements
Enumeration elements()Returns anEnumerationof all the Objects in all theILcdLayersubsets.- Returns:
- An
Enumerationof all the Objects in all theILcdLayersubsets.
-
size
int size()Returns the number of Objects in all theILcdLayersubsets.- Returns:
- The number of Objects in all the
ILcdLayersubsets.
-
contains
Checks ifaObjectis contained in one of the layer subsets of this list. Tests shall be done by comparing Object reference (not using Object.equals)- Parameters:
aObject- The object whose presence in this list is to be tested.- Returns:
trueif the givenObjectbelongs to one of theILcdLayersubsets, false otherwise.
-