public class NFERTreeSpatialModel extends java.lang.Object implements NFESpatialModel
Constructor and Description |
---|
NFERTreeSpatialModel(NFEModel model)
Allocates a new spatial model associated to the given NFE model
|
Modifier and Type | Method and Description |
---|---|
boolean |
addNetworkElementIndex(NFENetworkElement netElem)
Spatially-indexes a network element
|
java.util.Collection<NFEFeatureElement> |
getFeatureElements(java.awt.geom.Area area)
Gets all the feature elements interacting with the given area.
|
java.util.Collection<NFEFeatureElement> |
getFeatureElements(java.awt.geom.Area area, long featLayerId)
Gets all the feature elements interacting with the given area.
|
java.util.Collection<NFEFeatureElement> |
getFeatureElements(java.awt.geom.Point2D point, double tolerance)
Gets all the feature elements interacting with the given point.
|
java.util.Collection<NFEFeatureElement> |
getFeatureElements(java.awt.geom.Point2D point, double tolerance, long featLayerId)
Gets all the feature elements interacting with the given point.
|
java.util.Collection<NFEFeatureElement> |
getFeatureElements(java.awt.geom.Rectangle2D rect)
Gets all the feature elements interacting with the given rectangle.
|
java.util.Collection<NFEFeatureElement> |
getFeatureElements(java.awt.geom.Rectangle2D rect, long featLayerId)
Gets all the feature elements interacting with the given rectangle.
|
java.util.Collection<NFENetworkElement> |
getNetworkElements(java.awt.geom.Area area)
Gets all the network elements interacting with the given area.
|
java.util.Collection<NFENetworkElement> |
getNetworkElements(java.awt.geom.Point2D point, double tolerance)
Gets all the network elements interacting with the given point.
|
java.util.Collection<NFENetworkElement> |
getNetworkElements(java.awt.geom.Rectangle2D rect)
Gets all the network elements interacting with the given rectangle.
|
boolean |
refreshNetworkElementIndex(NFENetworkElement netElem)
Refreshes the spatial index of the network element to reflect its actual geometry.
|
boolean |
removeNetworkElementIndex(NFENetworkElement netElem)
Removes the index for the network element
|
public NFERTreeSpatialModel(NFEModel model)
model
- the current NFE modelpublic boolean addNetworkElementIndex(NFENetworkElement netElem)
NFESpatialModel
addNetworkElementIndex
in interface NFESpatialModel
netElem
- a network element instancepublic boolean refreshNetworkElementIndex(NFENetworkElement netElem)
NFESpatialModel
refreshNetworkElementIndex
in interface NFESpatialModel
netElem
- a network element instancepublic boolean removeNetworkElementIndex(NFENetworkElement netElem)
NFESpatialModel
removeNetworkElementIndex
in interface NFESpatialModel
netElem
- a network element instancepublic java.util.Collection<NFENetworkElement> getNetworkElements(java.awt.geom.Point2D point, double tolerance)
NFESpatialModel
getNetworkElements
in interface NFESpatialModel
point
- a spatial point in moodel's coordinate systemtolerance
- the maximum distance an element can be from the target geometry to be considered in the result.public java.util.Collection<NFENetworkElement> getNetworkElements(java.awt.geom.Rectangle2D rect)
NFESpatialModel
getNetworkElements
in interface NFESpatialModel
rect
- a rectangle in model's coordinate systempublic java.util.Collection<NFENetworkElement> getNetworkElements(java.awt.geom.Area area)
NFESpatialModel
getNetworkElements
in interface NFESpatialModel
area
- an area in model's coordinate systempublic java.util.Collection<NFEFeatureElement> getFeatureElements(java.awt.geom.Point2D point, double tolerance)
NFESpatialModel
getFeatureElements
in interface NFESpatialModel
point
- a spatial point in moodel's coordinate systemtolerance
- the maximum distance an element can be from the target geometry to be considered in the result.public java.util.Collection<NFEFeatureElement> getFeatureElements(java.awt.geom.Rectangle2D rect)
NFESpatialModel
getFeatureElements
in interface NFESpatialModel
rect
- a rectangle in model's coordinate systempublic java.util.Collection<NFEFeatureElement> getFeatureElements(java.awt.geom.Area area)
NFESpatialModel
getFeatureElements
in interface NFESpatialModel
area
- an area in model's coordinate systempublic java.util.Collection<NFEFeatureElement> getFeatureElements(java.awt.geom.Point2D point, double tolerance, long featLayerId)
NFESpatialModel
getFeatureElements
in interface NFESpatialModel
point
- a spatial point in moodel's coordinate systemtolerance
- the maximum distance an element can be from the target geometry to be considered in the result.featLayerId
- only feature elements from this feature layer are returned.public java.util.Collection<NFEFeatureElement> getFeatureElements(java.awt.geom.Rectangle2D rect, long featLayerId)
NFESpatialModel
getFeatureElements
in interface NFESpatialModel
rect
- a rectangle in model's coordinate systemfeatLayerId
- only feature elements from this feature layer are returned.public java.util.Collection<NFEFeatureElement> getFeatureElements(java.awt.geom.Area area, long featLayerId)
NFESpatialModel
getFeatureElements
in interface NFESpatialModel
area
- an area in model's coordinate systemfeatLayerId
- only feature elements from this feature layer are returned.