Package org.locationtech.jts.planargraph
Class DirectedEdgeStar
java.lang.Object
org.locationtech.jts.planargraph.DirectedEdgeStar
- Version:
- 1.7
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(DirectedEdge de) Adds a new member to this DirectedEdgeStar.Returns the coordinate for the node at which this star is basedint
Returns the number of edges around the Node associated with this DirectedEdgeStar.getEdges()
Returns the DirectedEdges, in ascending order by angle with the positive x-axis.int
getIndex
(int i) Returns value of i modulo the number of edges in this DirectedEdgeStar (i.e.int
getIndex
(DirectedEdge dirEdge) Returns the zero-based index of the given DirectedEdge, after sorting in ascending order by angle with the positive x-axis.int
Returns the zero-based index of the given Edge, after sorting in ascending order by angle with the positive x-axis.getNextCWEdge
(DirectedEdge dirEdge) Returns theDirectedEdge
on the right-hand (CW) side of the givenDirectedEdge
(which must be a member of this DirectedEdgeStar).getNextEdge
(DirectedEdge dirEdge) Returns theDirectedEdge
on the left-hand (CCW) side of the givenDirectedEdge
(which must be a member of this DirectedEdgeStar).iterator()
Returns an Iterator over the DirectedEdges, in ascending order by angle with the positive x-axis.void
remove
(DirectedEdge de) Drops a member of this DirectedEdgeStar.
-
Constructor Details
-
DirectedEdgeStar
public DirectedEdgeStar()Constructs a DirectedEdgeStar with no edges.
-
-
Method Details
-
add
Adds a new member to this DirectedEdgeStar. -
remove
Drops a member of this DirectedEdgeStar. -
iterator
Returns an Iterator over the DirectedEdges, in ascending order by angle with the positive x-axis. -
getDegree
public int getDegree()Returns the number of edges around the Node associated with this DirectedEdgeStar. -
getCoordinate
Returns the coordinate for the node at which this star is based -
getEdges
Returns the DirectedEdges, in ascending order by angle with the positive x-axis. -
getIndex
Returns the zero-based index of the given Edge, after sorting in ascending order by angle with the positive x-axis. -
getIndex
Returns the zero-based index of the given DirectedEdge, after sorting in ascending order by angle with the positive x-axis. -
getIndex
public int getIndex(int i) Returns value of i modulo the number of edges in this DirectedEdgeStar (i.e. the remainder when i is divided by the number of edges)- Parameters:
i
- an integer (positive, negative or zero)
-
getNextEdge
Returns theDirectedEdge
on the left-hand (CCW) side of the givenDirectedEdge
(which must be a member of this DirectedEdgeStar). -
getNextCWEdge
Returns theDirectedEdge
on the right-hand (CW) side of the givenDirectedEdge
(which must be a member of this DirectedEdgeStar).
-