FRAMES | NO FRAMES | Description | Parameters | Examples | Response |
URL | http://<geometryservice-url>/project |
---|---|
Parent Resource | Geometry Service |
The project operation is performed on a geometry service resource. The result of this operation is an array of projected geometries. This resource projects an array of input geometries from an input spatial reference to an output spatial reference.
From 10.1 onwards this operation will call Simplify on the input geometries
.
You can provide arguments to the project 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 projected. 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:{ "geometryType" : "<esriGeometryPoint | esriGeometryMultipoint | esriGeometryPolyline | esriGeometryPolygon | esriGeometryEnvelope>", "geometries" : [ <geometry1>, <geometry2> ] }
Note: Support for the The
{ Simple Syntax for point geometries:When using points, in addition to the JSON structures, you can specify the geometries with a simpler comma-separated syntax. Syntax:geometries=x1,
y1, x2, y2, ..., xn, yn Example: geometries=-104.53, 34.74, -63.53, 10.23
URL based:For a large set of geometries, you can specify a URL to the input geometries stored in a JSON structure in a file on a public server. The expected format of the file’s contents will be exactly the same as that expected if the geometries were directly embedded in the request.
Syntax: |
inSR | 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. |
outSR | Description: The well-known ID of the spatial reference or a spatial reference json object for the returned geometries. For a list of valid WKID values, see Projected coordinate Systems and Geographic coordinate Systems. |
transformation |
//This option was added at 10.1 Description: The well-known ID or a json object specifying the datum transformation to be applied on the projected geometries. If transformation is specified a value for transformForward parameter must also be specified. For a list of valid datum transformation ID values, see Datum Transformations . If Transformation is not specified, a search is made through a set of default GeoTransformations. Currently, the following default transformations are used when applicable: esriSRGeoTransformation_NAD_1927_TO_NAD_1983_NADCON, forward and reverse, WKID=1241 esriSRGeoTransformation_NAD1983_To_WGS1984_1, forward and reverse, WKID=1188 esriSRGeoTransformation_NAD1927_To_WGS1984_4, forward and reverse, WKID=1173 |
transformForward |
//This option was added at 10.1 Description: A boolean indicating whether to transform forward or not. The forward or reverse direction of transformation is implied in the name of the transformation. If transformation is specified a value for transformForward parameter must also be specified. Values: true | false
|
Example 1: Project the point [-117, 34] from WGS 84 (4326) to Web Mercator (102113).
http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer/project?{
"geometries" : [ <geometry1>, <geometry2> ]
}
{
"geometries" : [
{ "x" : -1.16362263726209E7, "y" : 4104255.01132978 },
{ "x" : -7072127.25009667, "y" : 1137314.06593893 }
]
}