Please enable JavaScript to view this site.

Version:

Navigation: Activities > Activity Reference

Get Geometry Relation (server) Activity

Prev Top Next More

Description

The Get Geometry Relation (server) activity computes the set of pairs of geometries from the input geometry arrays that belong to the specified relation. This server-based activity has more advanced features when compared to the standard Get Geometry Relation activity. The spatial relationship to be tested between the two input geometry arrays can be more easily defined with simple text inputs such as "cross", "intersection", or "disjoint". The standard DE-9IM relation string can also be used. For more information, see DE-9IM.

 

Another advance feature is the ability to input arrays of geometries for the Geometry1 and Geometry2 fields. This allows for comparing all geometries in Geometry1's array with all geometries in Geometry2's array.

Usage Examples

The section shows examples of determining geometry relationships by utilizing the Get Geometry Relation (server) activity.

Example 1: Geometries that touch

In this example, the two geometries have at least one point in common, but unlike the Intersects scheme, their interiors do not intersect.

Get_Geometry_Relation_9_dimensions_touch_example

To test for two geometries touching:

1.In the Geometry1 field, indicate the first geometry (a).

2.In the Geometry2 field, indicate the second geometry (b).

3.In the Relation field, indicate the intersection mask string of "touch".

4.If the output $geometryRelation1.incident is an array of the two geometries (esri.Geometry[]), then the two geometries are touching.

Example 2: Geometries that are disjointed

In this example, the two geometries have no point in common. They form a set of disconnected geometries. Disjoint is the opposite of Intersects.

Get_Geometry_Relation_9_dimensions_disjoint_example

To test for two geometries that are disjointed:

1.In the Geometry1 field, indicate the first geometry (a).

2.In the Geometry2 field, indicate the second geometry (b).

3.In the Relation field, indicate the intersection mask string of "disjoint".

4.If the output $geometryRelation1.incident is an array of the two geometries (esri.Geometry[]), then the two geometries are disjointed.

Example 3: Multiple geometries that are intersecting with a larger geometry

In this example, a large geometry has been created using the Geometry Picker form element. It intersects 42 geometries on the map. In this instance, you are using $geometryRelation1.incidents output to get an array of arrays signifying all geometries that intersect with the Geometry Picker's geometry.

Get_Geometry_Relation_9_dimensions_multiple_intersects

To test for multiple geometries intersecting with a larger geometry:

1.In the Geometry1 field, indicate the geometry (a) created using the Geometry Picker. This is an array with just one item.

2.In the Geometry2 field, input an array of visible geometries based on the map's extent.

3.In the Relation field, indicate the intersection mask string of "intersection".

4.The output $geometryRelation1.incidents is an array of geometry arrays (esri.Geometry[][]) signifying all visible geometries intersecting with Geometry1.

Inputs

Url

Required

Type: String

The URL of the ArcGIS geometry service.

For example, https://utility.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer.

Geometry1

Required

Type: esri.Geometry (3.x, 4.x)* | esri.Geometry[] (3.x, 4.x)*

The first array of geometries to compute the relation.

Geometry2

Required

Type: esri.Geometry (3.x, 4.x)* | esri.Geometry[] (3.x, 4.x)*

The second array of geometries to compute the relation.

Relation

Optional

Type: "cross" | "disjoint" | "in" | "interior-intersection" | "intersection" | "line-coincidence" | "line-touch" | "overlap" | "point-touch"| "touch"| "within" | String

The spatial relationship to be tested between the two input geometry arrays.

The default is "intersection".

Dimensionally Extended 9 Intersection Model (DE-9IM) matrix relation strings are also supported. See DE-9IM for more information.

* VertiGIS Studio Workflow uses different versions of Esri's ArcGIS API for JavaScript depending on the type of host application. See Underlying Technologies for information.

Outputs

incident

Type: esri.Geometry[] (3.x, 4.x)*

The array of geometries that meet the specified relation.

incidents

Type: esri.Geometry[][] (3.x, 4.x)*

The array of geometries that meet the specified relation.

* VertiGIS Studio Workflow uses different versions of Esri's ArcGIS API for JavaScript depending on the type of host application. See Underlying Technologies for information.

Properties

For information about the ID, Display Name, and Description properties, see Properties Common to all Activities.

Connectivity Requirements

This activity does not work when the device has intermittent connectivity to the network.

Version Information

Supported from: Geocortex Viewer for HTML5 2.9, ArcGIS Web AppBuilder 2.4.

See also...

https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-Geometry.html

© 2024 VertiGIS North America Ltd. All Rights Reserved. | Privacy Center | Imprint
Documentation Version 5.42 (58a5caf5)