Package org.locationtech.jts.geomgraph
Class EdgeEndStar
- java.lang.Object
-
- org.locationtech.jts.geomgraph.EdgeEndStar
-
- Direct Known Subclasses:
DirectedEdgeStar,EdgeEndBundleStar
public abstract class EdgeEndStar extends java.lang.ObjectA EdgeEndStar is an ordered list of EdgeEnds around a node. They are maintained in CCW order (starting with the positive x-axis) around the node for efficient lookup and topology building.- Version:
- 1.7
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.ListedgeListA list of all outgoing edges in the result, in CCW orderprotected java.util.MapedgeMapA map which maintains the edges in sorted order around the nodeprivate int[]ptInAreaLocationThe location of the point for this star in Geometry i Areas
-
Constructor Summary
Constructors Constructor Description EdgeEndStar()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description private booleancheckAreaLabelsConsistent(int geomIndex)private voidcomputeEdgeEndLabels(BoundaryNodeRule boundaryNodeRule)voidcomputeLabelling(GeometryGraph[] geomGraph)intfindIndex(EdgeEnd eSearch)CoordinategetCoordinate()intgetDegree()java.util.ListgetEdges()private intgetLocation(int geomIndex, Coordinate p, GeometryGraph[] geom)EdgeEndgetNextCW(EdgeEnd ee)abstract voidinsert(EdgeEnd e)Insert a EdgeEnd into this EdgeEndStarprotected voidinsertEdgeEnd(EdgeEnd e, java.lang.Object obj)Insert an EdgeEnd into the map, and clear the edgeList cache, since the list of edges has now changedbooleanisAreaLabelsConsistent(GeometryGraph geomGraph)java.util.Iteratoriterator()Iterator access to the ordered list of edges is optimized by copying the map collection to a list.voidprint(java.io.PrintStream out)(package private) voidpropagateSideLabels(int geomIndex)java.lang.StringtoString()
-
-
-
Field Detail
-
edgeMap
protected java.util.Map edgeMap
A map which maintains the edges in sorted order around the node
-
edgeList
protected java.util.List edgeList
A list of all outgoing edges in the result, in CCW order
-
ptInAreaLocation
private int[] ptInAreaLocation
The location of the point for this star in Geometry i Areas
-
-
Method Detail
-
insert
public abstract void insert(EdgeEnd e)
Insert a EdgeEnd into this EdgeEndStar
-
insertEdgeEnd
protected void insertEdgeEnd(EdgeEnd e, java.lang.Object obj)
Insert an EdgeEnd into the map, and clear the edgeList cache, since the list of edges has now changed
-
getCoordinate
public Coordinate getCoordinate()
- Returns:
- the coordinate for the node this star is based at
-
getDegree
public int getDegree()
-
iterator
public java.util.Iterator iterator()
Iterator access to the ordered list of edges is optimized by copying the map collection to a list. (This assumes that once an iterator is requested, it is likely that insertion into the map is complete).
-
getEdges
public java.util.List getEdges()
-
computeLabelling
public void computeLabelling(GeometryGraph[] geomGraph)
-
computeEdgeEndLabels
private void computeEdgeEndLabels(BoundaryNodeRule boundaryNodeRule)
-
getLocation
private int getLocation(int geomIndex, Coordinate p, GeometryGraph[] geom)
-
isAreaLabelsConsistent
public boolean isAreaLabelsConsistent(GeometryGraph geomGraph)
-
checkAreaLabelsConsistent
private boolean checkAreaLabelsConsistent(int geomIndex)
-
propagateSideLabels
void propagateSideLabels(int geomIndex)
-
findIndex
public int findIndex(EdgeEnd eSearch)
-
print
public void print(java.io.PrintStream out)
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-