Class NodingValidator


  • public class NodingValidator
    extends java.lang.Object
    Validates that a collection of SegmentStrings is correctly noded. Throws an appropriate exception if an noding error is found.
    Version:
    1.7
    • Constructor Detail

      • NodingValidator

        public NodingValidator​(java.util.Collection segStrings)
    • Method Detail

      • checkValid

        public void checkValid()
      • checkCollapses

        private void checkCollapses()
        Checks if a segment string contains a segment pattern a-b-a (which implies a self-intersection)
      • checkCollapses

        private void checkCollapses​(SegmentString ss)
      • checkInteriorIntersections

        private void checkInteriorIntersections()
        Checks all pairs of segments for intersections at an interior point of a segment
      • checkInteriorIntersections

        private void checkInteriorIntersections​(SegmentString e0,
                                                int segIndex0,
                                                SegmentString e1,
                                                int segIndex1)
      • hasInteriorIntersection

        private boolean hasInteriorIntersection​(LineIntersector li,
                                                Coordinate p0,
                                                Coordinate p1)
        Returns:
        true if there is an intersection point which is not an endpoint of the segment p0-p1
      • checkEndPtVertexIntersections

        private void checkEndPtVertexIntersections()
        Checks for intersections between an endpoint of a segment string and an interior vertex of another segment string
      • checkEndPtVertexIntersections

        private void checkEndPtVertexIntersections​(Coordinate testPt,
                                                   java.util.Collection segStrings)