Spatial Operations

Activity

 spatialoperations.png An OpenSpirit activity that performs spatial operations on two geometry inputs. The geometry types supported are Point, Line String and Polygon. The spatial operations that can be performed are: Contains, Crosses, Disjoint, Intersects, Overlaps, Touches and Within.

 

Configuration

OpenSpirit Spatial Operations Configuration Fields

Field Global Var? Optional? Description
Name No No User assigned name given to query activity
Description No Yes User assigned description (optional)
First Geometry No No Specifies the first geometry type. The options are: Point, Polygon, Line String and Esri WKT (See the Input section below on how these options effect the input). The default first geometry is Point.
Spatial Operator No No

Specifies the spatial operation to perform on the two geometries. The options are: Contains, Crosses, Disjoint, Intersects, Overlaps, Touches and Within. The default operator is "Within". The Spatial Operators table contains definitions of these operators.

Second Geometry No No Specifies the second geometry type. The options are Point, Polygon, Line String and Esri WKT (See the Input section below on how these options effect the input). The default second geometry is Polygon.

 

Input

See TIBCO ActiveMatrix BusinessWorks Process Design Guide for more information about mapping and transforming input data.

The input for the activity is the following.

Input Item Datatype Description
OspInput Complex Root element for all input elements
FirstGeometry Complex This will either be a Point, Polygon or Line String depending on the "First Geometry" combo box setting on the configuration panel. If "Esri WKT" is chosen, this field will not be displayed.
FirstEsriWKT String The Esri WKT for the first geometry. The value must represent a Point, Polygon or Line String. This input is only shown if "Esri WKT" is chosen in the "First Geometry" combo box.
FirstCRS OspCRS The coordinate system for the first geometry. This input is only shown if "Esri WKT" is chosen in the "First Geometry" combo box.
SpatialOperator String Optionally supply the spatial operator at runtime. If supplied, this value will override the "Spatial Operator" combo box on the configuration panel.
SecondGeometry Complex This will either be a Point, Polygon or Line String depending on the "Second Geometry" combo box setting on the configuration panel. If "Esri WKT" is chosen, this field will not be displayed.
SecondEsriWKT String The Esri WKT for the second geometry. The value must represent a Point, Polygon or Line String. This input is only shown if "Esri WKT" is chosen in the "Second Geometry" combo box.
SecondCRS OspCRS The coordinate system for the second geometry. This input is only shown if "Esri WKT" is chosen in the "Second Geometry" combo box.

 

Output

The output for the activity is the following.

Output Item Datatype Description

OspOutput

Complex The root element for all output items for the activity.
FirstGeometry Complex This will either be a Point, Polygon or Line String depending on the "First Geometry" combo box setting on the configuration panel. If "Esri WKT" is chosen, this field will not be displayed.
FirstEsriWKT String The Esri WKT for the first geometry. This output is only shown if "Esri WKT" is chosen in the "First Geometry" combo box.
FirstCRS OspCRS The coordinate system for the first geometry. This output is only shown if "Esri WKT" is chosen in the "First Geometry" combo box.
SpatialOperator String The spatial operator performed.
SecondGeometry Complex This will either be a Point, Polygon or Line String depending on the "Second Geometry" combo box setting on the configuration panel. If "Esri WKT" is chosen, this field will not be displayed.
SecondEsriWKT String The Esri WKT for the second geometry. This output is only shown if "Esri WKT" is chosen in the "Second Geometry" combo box.
SecondCRS OspCRS The coordinate system for the second geometry. This output is only shown if "Esri WKT" is chosen in the "Second Geometry" combo box.
Result Boolean The result of the spatial operator being applied to the two geometries.

 

Error Output

The Error Output tab lists the possible exceptions that can be thrown by this activity.

Exception Thrown When ...

OspException

    msg

    msgCode

The spatial operation could not be successfully executed.  
The msg element should contain some indication of the reason.
The error code (see list of possible  codes)

 

Spatial Operators

Spatial Operator Description
Contains The first geometry Contains the second if the second is Within the first. See the definition of Within below.
Crosses For two objects to cross, their Interiors must intersect and the Interior of one must intersect the Exterior of the other.. Examples:
crosses1.png          crosses2.png
Disjoint Two geometries are disjoint if neither their interiors nor boundaries intersect. Examples:
disjoint1.png          disjoint2.png
Intersects Two geometries Intersect if they are not Disjoint. See the definition of Disjoint above. Examples:
intersects1.png          intersects2.png
Overlaps Two geometries overlap if their interiors intersect and the interior of each intersects the exterior of the other. Examples:
overlaps1.png          overlaps2.png

Touches

Two geometries touch if their boundaries intersect the other's interiors or their boundaries intersect, but their interiors do not intersect. For instance, a point can touch a non-closed line segment only at the end-points (its boundaries). Examples:
touches1.png          touches2.png

Within

The first geometry is within the second geometry if the interiors of both geometries intersect, but the interior and boundary of the first does not intersect the exterior of the second. Examples:
within1.png          within2.png