# Class: DirectedEdgeStar

## jsts.geomgraph.DirectedEdgeStar

#### new DirectedEdgeStar()

A DirectedEdgeStar is an ordered list of outgoing DirectedEdges around a node. It supports labelling the edges as well as linking the edges to form both MaximalEdgeRings and MinimalEdgeRings.
Source:

### Members

#### (protected) edge :Edge

the parent edge of this edge end
• Edge
Inherited From:
Source:

• Label
Overrides:
Source:

### Methods

#### compareDirection(e) → {number}

Implements the total order relation:

a has a greater angle with the positive x-axis than b

Using the obvious algorithm of simply computing the angle is not robust, since the angle calculation is obviously susceptible to roundoff. A robust algorithm is: - first compare the quadrant. If the quadrants are different, it it trivial to determine which vector is "greater". - if the vectors lie in the same quadrant, the computeOrientation function can be used to decide the relative orientation of the vectors.

##### Parameters:
Name Type Description
`e` EdgeEnd
Inherited From:
Source:
Type
number

#### computeLabelling()

Compute the labelling for all dirEdges in this star, as well as the overall labelling
Source:

#### findCoveredLineEdges()

Traverse the star of edges, maintaing the current location in the result area at this node (if any). If any L edges are found in the interior of the result, mark them as covered.
Source:

#### (protected) init(p0, p1)

##### Parameters:
Name Type Description
`p0` Coordinate
`p1` Coordinate
Inherited From:
Source:

#### insert()

Insert a directed edge in the list
Source:

Traverse the star of DirectedEdges, linking the included edges together. To link two dirEdges, the pointer for an incoming dirEdge is set to the next outgoing edge.

• they belong to an area (i.e. they have sides)
• they are marked as being in the result

Edges are linked in CCW order (the order they are stored). This means that rings have their face on the Right (in other words, the topological location of the face is given by the RHS label of the DirectedEdge)

PRECONDITION: No pair of dirEdges are both marked as being in the result

Source:

#### mergeSymLabels()

For each dirEdge in the star, merge the label from the sym dirEdge into the label
Source:

#### updateLabelling()

Update incomplete dirEdge labels from the labelling for the node
Source: