public class DirectedEdgeStar extends Object
| Modifier and Type | Field and Description |
|---|---|
protected List |
outEdges
The underlying list of outgoing DirectedEdges
|
| Constructor and Description |
|---|
DirectedEdgeStar()
Constructs a DirectedEdgeStar with no edges.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(DirectedEdge
Adds a new member to this DirectedEdgeStar.
|
Coordinate |
getCoordinate()
Returns the coordinate for the node at wich this star is based
|
int |
getDegree()
Returns the number of edges around the Node associated with this DirectedEdgeStar.
|
List |
getEdges()
Returns the DirectedEdges, in ascending order by angle with the positive x-axis.
|
int |
getIndex(DirectedEdge
Returns the zero-based index of the given DirectedEdge, after sorting in ascending order by angle with the positive x-axis.
|
int |
getIndex(Edge
Returns the zero-based index of the given Edge, after sorting 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.
|
DirectedEdge |
getNextCWEdge(DirectedEdge
Returns the
DirectedEdge on the right-hand (CW) side of the given
DirectedEdge (which must be a member of this DirectedEdgeStar).
|
DirectedEdge |
getNextEdge(DirectedEdge
Returns the
DirectedEdge on the left-hand (CCW) side of the given
DirectedEdge (which must be a member of this DirectedEdgeStar).
|
Iterator |
iterator()
Returns an Iterator over the DirectedEdges, in ascending order by angle with the positive x-axis.
|
void |
remove(DirectedEdge
Drops a member of this DirectedEdgeStar.
|
protected ListoutEdges
public DirectedEdgeStar()
public void add(DirectedEdgede)
public void remove(DirectedEdgede)
public Iteratoriterator()
public int getDegree()
public CoordinategetCoordinate()
public ListgetEdges()
public int getIndex(Edgeedge)
public int getIndex(DirectedEdgedirEdge)
public int getIndex(int i)
i - an integer (positive, negative or zero)
public DirectedEdgegetNextEdge(DirectedEdge dirEdge)
DirectedEdge on the left-hand (CCW) side of the given
DirectedEdge (which must be a member of this DirectedEdgeStar).
public DirectedEdgegetNextCWEdge(DirectedEdge dirEdge)
DirectedEdge on the right-hand (CW) side of the given
DirectedEdge (which must be a member of this DirectedEdgeStar).