ArcGIS Runtime SDK for macOS

Spatial relationships

Description

This sample demonstrates how to use the AGSGeometryEngine to evaluate the spatial relationships between geometries.

How it works

Tap on the map to select the graphic and its geometry will be used to check the spatial relationships with other graphics geometries. The result will be displayed in a outline view.

The AGSGeometryEngine's geometry(_:crossesGeometry:), geometry(_:contains:), geometry(_:disjointTo:), geometry(_:intersects:), geometry(_:overlapsGeometry:), geometry(_:touchesGeometry:) and geometry(_:within:) methods are executed with selected graphic's geometry and other non-selected graphics geometries. If the method returns true, the relationship exists.


In this topic
  1. Description