relateWithPattern method

bool relateWithPattern(
  1. Geometry g,
  2. String intersectionPattern
)

Tests whether the elements in the DE-9IM {@link IntersectionMatrix} for the two Geometrys match the elements in intersectionPattern. The pattern is a 9-character string, with symbols drawn from the following set:

  • 0 (dimension 0)
  • 1 (dimension 1)
  • 2 (dimension 2)
  • T ( matches 0, 1 or 2)
  • F ( matches FALSE)
  • * ( matches any value)
For more information on the DE-9IM, see the OpenGIS Simple Features Specification.

@param g the Geometry with which to compare this Geometry @param intersectionPattern the pattern against which to check the intersection matrix for the two Geometrys @return true if the DE-9IM intersection matrix for the two Geometrys match intersectionPattern @see IntersectionMatrix

Implementation

bool relateWithPattern(Geometry g, String intersectionPattern) {
  return relate(g).matches(intersectionPattern);
}