ArcGIS REST API

Network Layer

Description

License:

The ArcGIS Pipeline Referencing for Server extension is required to use this resource.

Represents a network layer in a linear referencing geodatabase. A network layer can contain linear route features such as roads or pipelines.

Request Parameters

ParameterDetails
f

Description: The response format. The default response format is html.

Values: html | json

Example Usage

Example 1: URL for network layer ID 0.

http://sampleserver/arcgis/rest/services/MyLRS/MapServer/exts/LRServer/networkLayers/0

JSON Response Syntax

{
  "id" : <layerId>,
  "name" : "<layerName>",
  "type" : "<layerType>",  // esriLRSNetworkLayer
  "lrsNetworkId" : <networkId>,
  "datasetName" : "<datasetName>",  // the network name registered in the LRS dataset
  "featureClassName" : "<featureClassName>",  // the backing feature class name
  "unitsOfMeasure" : "<units>",
  "measurePrecision" : <precision>,
  "isDataVersioned" : <true | false>,
  "versionName" : "<versionName>",
  "dateFormat" : "<sqlDateFormat>",  //one of: esriLRSDateFormatStandard, esriLRSDateFormatFileGDB, esriLRSDateFormatOracle
  "spatialReferenceInfo" : {
    // spatial reference properties of the feature data
    "wkid" : <wkid>,
    "wkt" : "<wkt>",  // WKT is included only when there is no WKID available
    "xyResolution" : <xyResolution>,
    "xyTolerance" : <xyTolerance>,
    "mResolution" : <mResolution>,
    "mTolerance" : <mTolerance>
  },
  "routeIdFields" : [ "<fieldName1>", "<fieldName2>", ... ],
  "routeIdSeparator" : "<separator>",
  "routeIdFieldName" : "<fieldName>",
  "fromDateFieldName" : "<fieldName>",
  "toDateFieldName" : "<fieldName>",
  "routeNameFieldName" : "<fieldName>",
  "hasDominanceRules" : <true | false>,
  "autoGenerateRouteName" : <true | false>,

  // line support properties
  "supportsLines" : <true | false>,
  "lineIdFieldName" : "<fieldName>",
  "lineNameFieldName" : "<fieldName>",
  "lineOrderFieldName" : "<fieldName>",

  "lrs" : {
    "id" : "<id>",
    "name" : "<name>"
  },
  "eventLayers" : [
    { "id" : <layerId1>, "name" : "<layerName1>", "type" : "<layerType1>" },
    { "id" : <layerId2>, "name" : "<layerName2>", "type" : "<layerType2>" },
    ...
  ],
  "fields" : [
    {
      "name" : "<fieldName1>",
      "type" : "<fieldType1>",
      "alias" : "<fieldAlias1>",
      "length" : <length1>,
      "editable" : <true | false>,
      "nullable" : <true | false>,
      "defaultValue" : <defaultValue1>,
      "domain" : <domain1>
    },
    {
      "name" : "<fieldName2>",
      "type" : "<fieldType2>",
      "alias" : "<fieldAlias2>",
      "length" : <length2>,
      "editable" : <true | false>,
      "nullable" : <true | false>,
      "defaultValue" : <defaultValue2>,
      "domain" : <domain2>
    },
    ...
  ]
}

JSON Response Example

{
  "id" : 0,
  "name" : "Pipes",
  "type" : "esriLRSNetworkLayer",
  "lrsNetworkId" : 1,
  "datasetName" : "pipelines",
  "featureClassName" : "sde.pipelines",
  "unitsOfMeasure" : "esriMeters",
  "measurePrecision" : 3,
  "isDataVersioned" : true,
  "versionName" : "sde.DEFAULT",
  "dateFormat" : "esriLRSDateFormatStandard",
  "spatialReferenceInfo" : {
    "wkid" : 26918,
    "xyResolution" : 0.0001,
    "xyTolerance" : 0.001,
    "mResolution" : 0.0001,
    "mTolerance" : 0.001
  },
  "routeIdFields" : [ "RouteId" ],
  "routeIdSeparator" : "",
  "routeIdFieldName" : "RouteId",
  "fromDateFieldName" : "FromDate",
  "toDateFieldName" : "ToDate",
  "routeNameFieldName" : "RouteName",
  "hasDominanceRules" : false,
  "autoGenerateRouteName" : false,
  "supportsLines" : true,
  "lineIdFieldName" : "LineId",
  "lineNameFieldName" : "LineName",
  "lineOrderFieldName" : "LineOrder",
  "lrs" : {
    "id" : "DFB23B7D-69D1-460F-B7E0-0FB190D23B96",
    "name" : "LRS"
  },
  "eventLayers" : [
    { "id" : 1, "name" : "Valves", "type" : "esriLRSPointEventLayer" },
    { "id" : 2, "name" : "Pressure", "type" : "esriLRSLinearEventLayer" }
  ],
  "fields" : [
    {
      "name" : "ObjectID",
      "type" : "esriFieldTypeOID",
      "alias" : "Object ID",
      "editable" : false,
      "nullable" : false,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "RouteId",
      "type" : "esriFieldTypeString",
      "alias" : "Route ID",
      "length" : "38",
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "RouteName",
      "type" : "esriFieldTypeString",
      "alias" : "Route Name",
      "length" : 100,
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "FromDate",
      "type" : "esriFieldTypeDate",
      "alias" : "From Date",
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "ToDate",
      "type" : "esriFieldTypeDate",
      "alias" : "To Date",
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "LineId",
      "type" : "esriFieldTypeString",
      "alias" : "Line ID",
      "length" : 38,
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "LineName",
      "type" : "esriFieldTypeString",
      "alias" : "Line Name",
      "length" : 100,
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "LineOrder",
      "type" : "esriFieldTypeInteger",
      "alias" : "Line Order",
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    },
    {
      "name" : "Desc",
      "type" : "esriFieldTypeString",
      "alias" : "Description",
      "length" : 200,
      "editable" : true,
      "nullable" : true,
      "defaultValue" : null,
      "domain" : null
    }
  ]
}