FRAMES | NO FRAMES | Description | Parameters | Examples | Response |
URL | http://<geometryservice-url>/union |
---|---|
Parent Resource | Geometry Service |
The union operation is performed on a geometry service resource.This operation constructs the set-theoretic union of the geometries in the input array. All inputs must be of the same type.
From 10.1 onwards this operation will call Simplify on the input geometries
.
You can provide arguments to the union operation as query parameters defined in the parameters table below.
Parameter | Details |
---|---|
f | Description: The response format.
The default response format is html. Values: html | json |
geometries | Description: The
array of geometries to be unioned. The structure of each geometry in the array is
same as the structure of the json
geometry objects
returned by the ArcGIS REST API. Syntax and Examples: JSON Structures:Syntax:{ The
{ "geometryType":"esriGeometryPolygon", "geometries":[ { "rings" : [ [[-117,34],[-116,34],[-117,33],[-117,34]], [[-115,44],[-114,43],[-115,43],[-115,44]] ] }, { "rings" : [ [[32.49,17.83],[31.96,17.59],[30.87,17.01],[30.11,16.86],[32.49,17.83]] ] } ] } |
sr | Description: The well-known ID of
the spatial reference or a spatial reference json object for the input geometries . For a list of valid
WKID values, see Projected coordinate Systems
and Geographic coordinate Systems. |
Example 1: Union two multipoint geometries
http://sampleserver3.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer/union?sr=102113{
"geometryType" : "<esriGeometryPoint | esriGeometryMultipiont | esriGeometryPolyline | esriGeometryPolygon>"
"geometry" : <geometry>
}
{ "geometryType" : "esriGeometryMultipoint", "geometry" : { "points" : [ [-13721174.8048, 4991906.4582], [-13512647.4057, 4800770.1599], [-13512647.4057, 4991906.4582], [-13470941.9259, 4468209.699], [-13293693.6367, 4494424.7285], [-13199856.3072, 4133116.2506], [-13126871.7175, 4260779.643], [-12939197.0583, 4044613.1774], [-12918344.3184, 4222325.3283], [-12887065.2086, 3906909.4673], [-8418433.3989, 5262954.0867], [-8353363.7178, 5381714.5528], [-8250336.7228, 5337002.1307], [-8250336.7228, 5509587.1547] ] } }