lib/postgis_adapter/functions/common.rb
#
# Returns true if this Geometry is spatially related to anotherGeometry,
# by testing for intersections between the Interior, Boundary and Exterior
# of the two geometries as specified by the values in the
# intersectionPatternMatrix. If no intersectionPatternMatrix is passed in,
# then returns the maximum intersectionPatternMatrix that relates the 2 geometries.
#
#
# Version 1: Takes geomA, geomB, intersectionMatrix and Returns 1 (TRUE) if
# this Geometry is spatially related to anotherGeometry, by testing for
# intersections between the Interior, Boundary and Exterior of the two
# geometries as specified by the values in the intersectionPatternMatrix.
#
# This is especially useful for testing compound checks of intersection,
# crosses, etc in one step.
#
# Do not call with a GeometryCollection as an argument
#
# This is the "allowable" version that returns a boolean, not an integer.
# This is defined in OGC spec.
# This DOES NOT automagically include an index call. The reason for that
# is some relationships are anti e.g. Disjoint. If you are using a relationship
# pattern that requires intersection, then include the && index call.
#
# Version 2: Takes geomA and geomB and returns the DE-9IM
# (dimensionally extended nine-intersection matrix)
#
# Do not call with a GeometryCollection as an argument
# Not in OGC spec, but implied. see s2.1.13.2
#
#  Both Performed by the GEOS module
#
#  Returns:
#
#  String ST_Relate(geometry geomA, geometry geomB);
#  Boolean ST_Relate(geometry geomA, geometry geomB, text intersectionPatternMatrix);
#
Returns true if this Geometry is spatially related to anotherGeometry,
by testing for intersections between the Interior, Boundary and Exterior
of the two geometries as specified by the values in the
intersectionPatternMatrix. If no intersectionPatternMatrix is passed in,
then returns the maximum intersectionPatternMatrix that relates the 2 geometries.

Version 1: Takes geomA, geomB, intersectionMatrix and Returns 1 (TRUE) if
this Geometry is spatially related to anotherGeometry, by testing for
intersections between the Interior, Boundary and Exterior of the two
geometries as specified by the values in the intersectionPatternMatrix.

This is especially useful for testing compound checks of intersection,
crosses, etc in one step.

Do not call with a GeometryCollection as an argument

This is the "allowable" version that returns a boolean, not an integer.
This is defined in OGC spec.
This DOES NOT automagically include an index call. The reason for that
is some relationships are anti e.g. Disjoint. If you are using a relationship
pattern that requires intersection, then include the && index call.

Version 2: Takes geomA and geomB and returns the DE-9IM
(dimensionally extended nine-intersection matrix)

Do not call with a GeometryCollection as an argument
Not in OGC spec, but implied.

Both Performed by the GEOS module




Returns true if this Geometry is spatially related to anotherGeometry by testing for intersections between the Interior Boundary and Exterior of the two geometries as specified by the values in the intersectionPatternMatrix . If no intersectionPatternMatrix is passed in then returns the maximum intersectionPatternMatrix that relates the 2 geometries . Version 1 : Takes geomA geomB intersectionMatrix and Returns 1 ( TRUE ) if this Geometry is spatially related to anotherGeometry by testing for intersections between the Interior Boundary and Exterior of the two geometries as specified by the values in the intersectionPatternMatrix . This is especially useful for testing compound checks of intersection crosses etc in one step . Do not call with a GeometryCollection as an argument This is the " allowable " version that returns a boolean not an integer . This is defined in OGC spec . This DOES NOT automagically include an index call . The reason for that is some relationships are anti e . g . Disjoint . If you are using a relationship pattern that requires intersection then include the && index call . Version 2 : Takes geomA and geomB and returns the DE - 9IM ( dimensionally extended nine - intersection matrix ) Do not call with a GeometryCollection as an argument Not in OGC spec but implied . Both Performed by the GEOS module
def relate?(other, m = nil)
    m = "'#{m}'" if m
    postgis_calculate("Relate", [self, other], m)
  end
def relate? ( other , m = nil ) m = "'#{m}'" if m postgis_calculate ( "Relate" , [ self , other ] , m ) end
Returns true if this Geometry is spatially related to anotherGeometry,
by testing for intersections between the Interior, Boundary and Exterior
of the two geometries as specified by the values in the
intersectionPatternMatrix.
Returns true if this Geometry is spatially related to anotherGeometry by testing for intersections between the Interior Boundary and Exterior of the two geometries as specified by the values in the intersectionPatternMatrix .
# Relate is case sentitive.......
other
<not_specific>
m
<not_specific>