isNodeConsistentArea method

bool isNodeConsistentArea()

Check all nodes to see if their labels are consistent with area topology.

@return true if this area has a consistent node labelling

Implementation

bool isNodeConsistentArea() {
  /**
   * To fully check validity, it is necessary to
   * compute ALL intersections, including self-intersections within a single edge.
   */
  SegmentIntersector intersector =
      geomGraph.computeSelfNodes3(li, true, true);
  /**
   * A proper intersection means that the area is not consistent.
   */
  if (intersector.hasProperIntersection()) {
    invalidPoint = intersector.getProperIntersectionPoint();
    return false;
  }

  nodeGraph.build(geomGraph);

  return isNodeEdgeAreaLabelsConsistent();
}