All Layers and Tables

Description

The layers resource represents all the layers and stand-alone tables under a map service published using ArcGIS Server. It provides basic information about the layers and tables such as name, type, parent and sub-layers, fields, min and max scales, extent, and copyright text.

New at 10.6

New at 10.2

New at 10.1 SP1

New at 10.1

Support for dynamicLayers was added.

Request parameters

Parameter

Details

f

The response format. The default response format is html.

Values: html | json

dynamicLayers

This option was added at 10.1.

Description: Dynamic layers definition. This parameter is required to generate a layers resource for dynamic layers.

NoteNote:

supportsDynamicLayers on the map service resource should be true to use the dynamicLayers property when requesting layers resource.

Syntax: [dynamicLayer1,dynamicLayer2,...,dynamicLayerN]

returnDomainNames

This parameter was added at 10.6

Description: If value is true, then domain information provided in the layer includes only the domain name. To get the full domain information, use the queryDomains operation in the service resource. This domains included in the layer can be used to linked to the full domain information via the domain name. If the value is false or not set, then full domain information is included in the layer as it was in past releases.

Example usage

Example 1:

https://sampleserver6.arcgisonline.com/arcgis/rest/services/Census/MapServer/layers

Example 2: Using dynamicLayers

https://sampleserver6.arcgisonline.com/arcgis/rest/services/Census/MapServer/layers?dynamicLayers=[{"id":101,"source":{"type":"mapLayer","mapLayerId":0}}]&f=pjson

JSON Response syntax

{
"layers" : [
   {
     <layer1>
   },
   {
     <layer2>
   }
 ], 
 "tables" : [
   {
     <table1>
   },
   {
     <table2>
   }
 ]   
}

JSON Response example

{
  "layers" : [
    {
      "id" : 0, 
      "name" : "Wells", 
      "type" : "Feature Layer", 
      "description" : "", 
      "definitionExpression" : "", 
      "geometryType" : "esriGeometryPoint", 
      "copyrightText" : "", 
      "parentLayer" : null, 
      "subLayers" : [], 
      "minScale" : 0, 
      "maxScale" : 0, 
      "defaultVisibility" : false, 
      "extent" : {
        "xmin" : -102.048629, 
        "ymin" : 5.6843418860808E-14, 
        "xmax" : 5.6843418860808E-14, 
        "ymax" : 40.0020000000001, 
        "spatialReference" : {
          "wkid" : 4267
        }
      }, 
      "hasAttachments" : false, 
      "timeInfo" : {
        "startTimeField" : "COMPLETION", 
        "endTimeField" : "PLUG_DATE", 
        "trackIdField" : null, 
        "timeExtent" : [
          -2556057600000, 
          1246060800000
        ], "timeReference" : null, 
        "timeInterval" : 3, 
        "timeIntervalUnits" : "esriTimeUnitsYears", 
        "exportOptions" : {
          "useTime" : true, 
          "






  
	Ошибка приложения


    

Esri Logo

ArcGIS Web Adaptor

Не удалось получить доступ ни к одному из компьютеров сервера. Свяжитесь с системным администратором.