GEOS: geos::operation::valid::ConsistentAreaTester Class Reference

- Main Page
- Namespaces
- Classes
- Files
- Related Pages

- Class List
- Class Hierarchy
- Class Members

# geos::operation::valid::ConsistentAreaTester Class Reference

Checks that a geomgraph::GeometryGraph representing an area (a Polygon or MultiPolygon ) is consistent with the SFS semantics for area geometries. More...

`#include <ConsistentAreaTester.h>`

List of all members.

## Public Member Functions
| ConsistentAreaTester (geomgraph::GeometryGraph *newGeomGraph)
| Caller keeps responsibility for GeometryGraph deletion.
geom::Coordinate & | getInvalidPoint ()
bool | isNodeConsistentArea ()
bool | hasDuplicateRings ()

## Detailed Description

Checks that a geomgraph::GeometryGraph representing an area (a Polygon or MultiPolygon ) is consistent with the SFS semantics for area geometries.

Checks include:

- testing for rings which self-intersect (both properly and at nodes)
- testing for duplicate rings

If an inconsistency if found the location of the problem is recorded.

## Member Function Documentation

geom::Coordinate& geos::operation::valid::ConsistentAreaTester::getInvalidPoint | ( |  | ) |

Returns:
  the intersection point, or `null` if none was found

bool geos::operation::valid::ConsistentAreaTester::hasDuplicateRings | ( |  | ) |

Checks for two duplicate rings in an area. Duplicate rings are rings that are topologically equal (that is, which have the same sequence of points up to point order). If the area is topologically consistent (determined by calling the `isNodeConsistentArea`, duplicate rings can be found by checking for EdgeBundles which contain more than one geomgraph::EdgeEnd. (This is because topologically consistent areas cannot have two rings sharing the same line segment, unless the rings are equal). The start point of one of the equal rings will be placed in invalidPoint.

Returns:
  true if this area Geometry is topologically consistent but has two duplicate rings

The documentation for this class was generated from the following file:

- ConsistentAreaTester.h