Class SpatialRTree.Vertices<V>
- java.lang.Object
- 
- org.jungrapht.visualization.spatial.AbstractSpatial<T,NT>
- 
- org.jungrapht.visualization.spatial.SpatialRTree<V,V>
- 
- org.jungrapht.visualization.spatial.SpatialRTree.Vertices<V>
 
 
 
- 
- All Implemented Interfaces:
- LayoutStateChange.Listener,- LayoutVertexPositionChange.Listener<V>,- Spatial<V,V>
 - Enclosing class:
- SpatialRTree<T,NT>
 
 public static class SpatialRTree.Vertices<V> extends SpatialRTree<V,V> implements Spatial<V,V>, LayoutVertexPositionChange.Listener<V> 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classSpatialRTree.Vertices.Builder<V>- 
Nested classes/interfaces inherited from class org.jungrapht.visualization.spatial.SpatialRTreeSpatialRTree.Edges<E,V>, SpatialRTree.Vertices<V>
 - 
Nested classes/interfaces inherited from interface org.jungrapht.visualization.spatial.SpatialSpatial.NoOp<T,NT>
 
- 
 - 
Field Summary- 
Fields inherited from class org.jungrapht.visualization.spatial.SpatialRTreeboundingRectangleCollector, reinsert, rtree, splitterContext
 - 
Fields inherited from class org.jungrapht.visualization.spatial.AbstractSpatialgridCache, layoutModel, pickShapes, rectangle
 
- 
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static SpatialRTree.Vertices.Builderbuilder()protected List<Shape>collectGrids(List<Shape> list, RTree<V> tree)gather the RTree nodes into a list for display as PaintablesVgetClosestElement(double x, double y)get the node that is closest to the passed (x,y)VgetClosestElement(Point2D p)Set<V>getVisibleElements(Shape shape)voidlayoutVertexPositionChanged(LayoutVertexPositionChange.Event<V> evt)voidlayoutVertexPositionChanged(LayoutVertexPositionChange.GraphEvent<V> evt)voidrecalculate()rebuild the data structure // * // * @param elements the elements to insert into the data structurevoidupdate(V element, Point location)update the position of the passed node- 
Methods inherited from class org.jungrapht.visualization.spatial.SpatialRTreebulkInsert, clear, getContainingLeaf, getContainingLeafs, getContainingLeafs, getGrid, getLayoutArea, isReinsert, recalculate, setBounds, setReinsert, toString
 - 
Methods inherited from class org.jungrapht.visualization.spatial.AbstractSpatialgetClosest, getLayoutModel, getPickShapes, isActive, layoutStateChanged, setActive
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 - 
Methods inherited from interface org.jungrapht.visualization.layout.event.LayoutStateChange.ListenerlayoutStateChanged
 - 
Methods inherited from interface org.jungrapht.visualization.spatial.Spatialclear, getContainingLeaf, getContainingLeafs, getContainingLeafs, getGrid, getLayoutArea, getLayoutModel, getPickShapes, getUnion, getUnion, isActive, setActive, setBounds
 
- 
 
- 
- 
- 
Method Detail- 
builderpublic static SpatialRTree.Vertices.Builder builder() 
 - 
getVisibleElementspublic Set<V> getVisibleElements(Shape shape) - Specified by:
- getVisibleElementsin interface- Spatial<V,V>
- Parameters:
- shape- the possibly non-rectangular area of interest
- Returns:
- all nodes that are contained within the passed Shape
 
 - 
getClosestElementpublic V getClosestElement(Point2D p) - Specified by:
- getClosestElementin interface- Spatial<V,V>
- Parameters:
- p- a point to search in the spatial structure
- Returns:
- the closest element to the passed point
 
 - 
getClosestElementpublic V getClosestElement(double x, double y) get the node that is closest to the passed (x,y)- Specified by:
- getClosestElementin interface- Spatial<V,V>
- Parameters:
- x-
- y-
- Returns:
- the node closest to x,y
 
 - 
collectGridsprotected List<Shape> collectGrids(List<Shape> list, RTree<V> tree) Description copied from class:SpatialRTreegather the RTree nodes into a list for display as Paintables- Specified by:
- collectGridsin class- SpatialRTree<V,V>
- Returns:
 
 - 
recalculatepublic void recalculate() rebuild the data structure // * // * @param elements the elements to insert into the data structure- Specified by:
- recalculatein interface- Spatial<V,V>
 
 - 
layoutVertexPositionChangedpublic void layoutVertexPositionChanged(LayoutVertexPositionChange.GraphEvent<V> evt) - Specified by:
- layoutVertexPositionChangedin interface- LayoutVertexPositionChange.Listener<V>
 
 - 
layoutVertexPositionChangedpublic void layoutVertexPositionChanged(LayoutVertexPositionChange.Event<V> evt) - Specified by:
- layoutVertexPositionChangedin interface- LayoutVertexPositionChange.Listener<V>
 
 
- 
 
-