- URL:
- https://<network-layer-url>/checkEvents
- Methods:
GET
- Required Capability:
- The ArcGIS Location Referencing license is required to use this resource.
- Version Introduced:
- 10.6
Description
This operation detects common types of quality control errors in event data, such as the following:
- Gap—A section of a route where no event is defined for a given event layer.
- Overlap—A section of a route where more than one event is defined for a given event layer.
- Invalid measure—Reported when an event extends beyond the range of measures defined for a route.
Request parameters
Parameter | Details |
---|---|
(Optional) |
Specifies the response format. The default response format is Values: |
(Required) | A comma-separated list of layer IDs for the event layers to analyze. Example:
|
(Required) | A list of routes and measure ranges to analyze. Syntax:
|
| A comma-separated list of route IDs for the routes to analyze. The list must be in JSON array form to preserve any space characters in route IDs. Example:
|
| A comma-separated list of line IDs corresponding to the routes to analyze. This parameter applies only to networks that support lines. The list must be in JSON array form to preserve any space characters in line IDs. Example:
|
| If Values: |
| If Values: |
| If Values: |
|
The time instant to use as a temporal view date when locating route features. If this parameter is not specified, the current date is used. The parameter value is a number that represents the number of milliseconds since epoch (January 1, 1970) in UTC. Syntax:
Example:
|
| If Values: |
| Specifies the maximum allowable offset to be used for generalizing geometries returned in the results. This parameter can be used to reduce the size of the response data. The Example:
|
|
The spatial reference of the returned geometry. The spatial reference can be specified as either a Well-Known ID (WKID) or a spatial reference JSON object. If |
(Optional) |
Specifies the geodatabase version to use. If this parameter is not specified, the published map's version is used. Syntax:
Example:
|
(Optional) |
Specifies the historic moment to query. This parameter applies only if the layer is branch versioned and refers to geodatabase time (separate from LRS time). If this parameter is not specified, the query applies to the current features. Syntax:
Example:
|
Example usage
Example 1
URL for checking for event gaps on a single route and a single event layer.
https://sampleserver/arcgis/rest/services/MyLRS/MapServer/exts/LRServer/networkLayers/0/checkEvents?f=json&eventLayerIds=\[3]&routeIds=\["I90"]&checkGaps=true&outSR=102100
Example 2
URL for checking for event gaps and overlaps on a route section and a single event layer.
https://sampleserver/arcgis/rest/services/MyLRS/MapServer/exts/LRServer/networkLayers/0/checkEvents?f=json&eventLayerIds=\[4]&locations=\[{'{'}"routeId":"I90","fromMeasure":0.5,"toMeasure":1.75{'}'}]&checkGaps=true&checkOverlaps=true
Example 3
URL for checking for all error types on multiple routes and multiple event layers.
https://sampleserver/arcgis/rest/services/MyLRS/MapServer/exts/LRServer/networkLayers/0/checkEvents?f=json&eventLayerIds=\[3,5,6,7]&routeIds=\["I90","US20"]&checkGaps=true&checkOverlaps=true&checkMeasuresNotOnRoute=true
JSON Response syntax
{
"": <spatialReference>,
"results": [
{
"type": "<errorType>", // Gap, Overlap, MeasureNotOnRoute
"layerId": <eventLayerId>,
"routeId": "<routeId>",
"routeName": "<routeName>",
"toRouteId": "<routeId>", // only for event layers that can span routes
"toRouteName": "<routeName>", // only for event layers that can span routes
"lineId": "<lineId>", // only for event layers that can span routes
"lineName": "<lineName>", // only for event layers that can span routes
"eventId": "<eventId>", // only for MeasureNotOnRoute
"fromMeasure":< fromMeasure>,
"toMeasure": <toMeasure>,
"geometryType": "<geometryType>", // esriGeometryPolyline (for Gap and Overlap), esriGeometryMultipoint (for MeasureNotOnRoute)
"geometry": <geometry>
},
...
]
}
JSON Response example
{
"": { "wkid": 102100 },
"results": [
{
"type": "Gap",
"layerId": 3,
"routeId": "I90",
"fromMeasure": 0.2,
"toMeasure": 1.55,
"geometryType": "esriGeometryPolyline",
"geometry": { "paths": [ [ [-8704473, 5352043], [-8710354, 5360311], [-8704419, 5352063] ] ] }
},
{
"type": "Overlap",
"layerId": 3,
"routeId": "I90",
"fromMeasure": 2.0,
"toMeasure": 2.7,
"geometryType": "esriGeometryPolyline",
"geometry": { "paths": [ [ [-8704419, 5352063], [-8710014, 5360361] ] ] }
},
{
"type": "MeasureNotOnRoute",
"layerId": 5,
"routeId": "I90",
"eventId": "1348",
"fromMeasure": 0,
"toMeasure": 10.4,
"geometryType": "esriGeometryMultipoint",
"geometry": { "points": [ [-8710037, 5360371], [-8704473, 5352043] ] }
}
]
}