Class: EdgeEndBundle

jsts.operation.relate.EdgeEndBundle

new EdgeEndBundle()

A collection of EdgeEnds which obey the following invariant: They originate at the same node and have the same direction.
Source:

Extends

Members

(protected) edge :Edge

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

(protected) label :Label

Type:
  • 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:
Returns:
Type
number

computeLabel()

This computes the overall edge label for the set of edges in this EdgeStubBundle. It essentially merges the ON and side labels for each edge. These labels must be compatible
Source:

(protected) init(p0, p1)

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