com.vividsolutions.jts.geomgraph
Class EdgeIntersectionList

java.lang.Object
  extended bycom.vividsolutions.jts.geomgraph.EdgeIntersectionList

public class EdgeIntersectionList
extends java.lang.Object

A list of edge intersections along an Edge

Version:
1.4.0

Constructor Summary
EdgeIntersectionList(Edge edge)
           
 
Method Summary
 EdgeIntersection add(Coordinate intPt, int segmentIndex, double dist)
          Adds an intersection into the list, if it isn't already there.
 void addEndpoints()
          Adds entries for the first and last points of the edge to the list
 void addSplitEdges(java.util.List edgeList)
          Creates new edges for all the edges that the intersections in this list split the parent edge into.
 boolean isIntersection(Coordinate pt)
          This routine searches the list for the insertion point for the given intersection (which must be in normalized form).
 java.util.Iterator iterator()
          returns an iterator of EdgeIntersections
 void print(java.io.PrintStream out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EdgeIntersectionList

public EdgeIntersectionList(Edge edge)
Method Detail

add

public EdgeIntersection add(Coordinate intPt,
                            int segmentIndex,
                            double dist)
Adds an intersection into the list, if it isn't already there. The input segmentIndex and dist are expected to be normalized.

Returns:
the EdgeIntersection found or added

iterator

public java.util.Iterator iterator()
returns an iterator of EdgeIntersections


isIntersection

public boolean isIntersection(Coordinate pt)
This routine searches the list for the insertion point for the given intersection (which must be in normalized form). The intersection point may already be in the list - in this case, the intersection is not inserted. If the intersection is new, it is inserted into the list. The insertIt iterator is left pointing at the correct place to insert the intersection, if the intersection was not found.

Returns:
true if this intersection is already in the list

addEndpoints

public void addEndpoints()
Adds entries for the first and last points of the edge to the list


addSplitEdges

public void addSplitEdges(java.util.List edgeList)
Creates new edges for all the edges that the intersections in this list split the parent edge into. Adds the edges to the input list (this is so a single list can be used to accumulate all split edges for a Geometry).


print

public void print(java.io.PrintStream out)