Class AbstractSelection

java.lang.Object
com.vividsolutions.jump.workbench.ui.AbstractSelection
Direct Known Subclasses:
FeatureSelection, LineStringSelection, PartSelection

public abstract class AbstractSelection extends Object
Superclass for holding a user-selected collection of Feature items.
  • Constructor Details

    • AbstractSelection

      public AbstractSelection(SelectionManager selectionManager)
  • Method Details

    • getRendererContentID

      public abstract String getRendererContentID()
    • items

      public abstract List<org.locationtech.jts.geom.Geometry> items(org.locationtech.jts.geom.Geometry geometry)
      Each selection implementation has the responsability to return the list of items composing a parent geometry.
    • items

      public List<org.locationtech.jts.geom.Geometry> items(org.locationtech.jts.geom.Geometry geometry, Collection<Integer> indices)
      Returns items having these indices in geometry.
      Parameters:
      geometry - geometry to analyse
      indices - indices of wanted geometries
    • getFeatureToSelectedItemIndexCollectionMap

      public Map<Feature, Set<Integer>> getFeatureToSelectedItemIndexCollectionMap(Layer layer)
      Returns a mapping of each feature to indices of selected items in this feature. Note that some features in the map may not have selected items.
    • getSelectedItemIndices

      public Set<Integer> getSelectedItemIndices(Layer layer, Feature feature)
      Returns indices of selected items in this feature.
    • getFeatureToSelectedItemCollectionMap

      public Map<Feature, List<org.locationtech.jts.geom.Geometry>> getFeatureToSelectedItemCollectionMap(Layer layer)
      Returns a mapping of each feature to selected items in this feature.
    • getLayersWithSelectedItems

      public Collection<Layer> getLayersWithSelectedItems()
    • getFeaturesWithSelectedItems

      public Collection<Feature> getFeaturesWithSelectedItems()
    • getFeaturesWithSelectedItems

      public Collection<Feature> getFeaturesWithSelectedItems(Layer layer)
    • getSelectedItems

      public Collection<org.locationtech.jts.geom.Geometry> getSelectedItems()
    • getSelectedItems

      public Collection<org.locationtech.jts.geom.Geometry> getSelectedItems(Layer layer)
    • getSelectedItems

      public Collection<org.locationtech.jts.geom.Geometry> getSelectedItems(Layer layer, Feature feature)
    • getSelectedItems

      public Collection<org.locationtech.jts.geom.Geometry> getSelectedItems(Layer layer, Feature feature, org.locationtech.jts.geom.Geometry geometry)
      Parameters:
      geometry - the feature's Geometry or equivalent; that is, a clone or similar enough Geometry from which Geometries can be retrieved using the selection indices.
    • indices

      public Set<Integer> indices(org.locationtech.jts.geom.Geometry geometry, Collection<org.locationtech.jts.geom.Geometry> items)
      Returns indices of items in geometry.
    • unselectItems

      public void unselectItems(Layer layer, Map<Feature, List<org.locationtech.jts.geom.Geometry>> featureToItemCollectionMap)
    • selectItems

      public void selectItems(Layer layer, Map<Feature, List<org.locationtech.jts.geom.Geometry>> featureToItemCollectionMap)
    • selectItems

      public void selectItems(Layer layer, Feature feature, Collection<org.locationtech.jts.geom.Geometry> items)
    • unselectItems

      public void unselectItems(Layer layer, Feature feature, Collection<org.locationtech.jts.geom.Geometry> items)
    • itemsNotSelectedInAncestors

      public Collection<org.locationtech.jts.geom.Geometry> itemsNotSelectedInAncestors(Layer layer, Feature feature, Collection<org.locationtech.jts.geom.Geometry> items)
    • selectedInAncestors

      protected abstract boolean selectedInAncestors(Layer layer, Feature feature, org.locationtech.jts.geom.Geometry item)
    • unselectInDescendants

      protected abstract void unselectInDescendants(Layer layer, Feature feature, Collection<org.locationtech.jts.geom.Geometry> items)
    • selectItems

      public void selectItems(Layer layer, Feature feature)
    • selectItems

      public void selectItems(Layer layer, Collection features)
    • unselectFromFeaturesWithModifiedItemCounts

      public void unselectFromFeaturesWithModifiedItemCounts(Layer layer, Collection<Feature> features, Collection<Feature> oldFeatureClones)
    • unselectItems

      public void unselectItems()
    • unselectItems

      public void unselectItems(Layer layer)
    • unselectItems

      public void unselectItems(Layer layer, Collection features)
    • unselectItems

      public void unselectItems(Layer layer, Feature feature)
    • unselectItem

      public void unselectItem(Layer layer, Feature feature, int selectedItemIndex)
    • setChild

      public void setChild(AbstractSelection child)
    • setParent

      public void setParent(AbstractSelection parent)
    • getChild

      protected AbstractSelection getChild()
    • getParent

      protected AbstractSelection getParent()