- URL:
- https://<root>/<serviceName>/FeatureServer/queryDomains
- Methods:
GET
- Version Introduced:
- 10.5
Description
The query
operation processes an array of layer IDs for a feature service and returns the full domain information for domains referenced by those layers. Support for this operation in indicated when the feature service has the supports
property set to true
.
This operation can be used by clients to efficiently work with domains. For example, a client can use the query
operation once to get and cache domain information. Clients can then set the return
parameter as true
on a feature layer resource to get just the domain names from the layer. The domain names returned from the feature layer resource can then be used to find the full domain information in the cache.
Request parameters
Parameter | Details |
---|---|
| An array of layers IDs. The domains returned from this request are the domains referenced by the specified layers. Syntax
Example
|
| The response format. The default response format is html. Values: |
Example usage
The following is a sample request for the query
operation:
https://machine.domain.com/webadaptor/rest/services/PoolPermits/FeatureServer/queryDomains?layers=[0,1,2,3,4,5,6]&f=pjson
JSON Response syntax
{
"domains": [
{
"type": "<domainType>",
"name": "<domainName>",
"fieldType": "<esriFieldType>",
"range": [
<minValue>,
<maxValue>
],
"mergePolicy": "<mergePolicy>",
"splitPolicy": "<splitPolicy>"
},
{
"type": "<domainType>",
"name": "<domainName2>",
"fieldType": "<esriFieldType>",
"codedValues": [
{
"name": "<codedValueDescription1>",
"code": <codedValue1>
},
{
"name": "<codedValueDescription2>",
"code": <codedValue2>
},
],
"mergePolicy": "<mergePolicy>",
"splitPolicy": "<splitPolicy>"
}
]
}
JSON Response example
{
"domains": [
{
"type": "range",
"name": "RDOM_1",
"fieldType": "esriFieldTypeInteger",
"range": [
1,
50
],
"mergePolicy": "esriMPTDefaultValue",
"splitPolicy": "esriSPTDefaultValue"
},
{
"type": "range",
"name": "RDOM_3",
"fieldType": "esriFieldTypeDouble",
"range": [
100,
150.5
],
"mergePolicy": "esriMPTDefaultValue",
"splitPolicy": "esriSPTDefaultValue"
},
{
"type": "codedValue",
"name": "CDOM_1",
"fieldType": "esriFieldTypeDouble",
"codedValues": [
{
"name": "code 1 description",
"code": 1
},
{
"name": "code 1.5 description",
"code": 1.5
},
{
"name": "code 2 description",
"code": 2
},
{
"name": "code 2.5 description",
"code": 2.5
}
],
"mergePolicy": "esriMPTDefaultValue",
"splitPolicy": "esriSPTDefaultValue"
},
{
"type": "codedValue",
"name": "CDOM_3",
"fieldType": "esriFieldTypeInteger",
"codedValues": [
{
"name": "code 100 description",
"code": "code 100"
},
{
"name": "code 200 description",
"code": "code 200"
},
{
"name": "code 300 description",
"code": "code 300"
}
],
"mergePolicy": "esriMPTDefaultValue",
"splitPolicy": "esriSPTDefaultValue"
},
{
"type": "codedValue",
"name": "CDOM_4",
"fieldType": "esriFieldTypeDouble",
"codedValues": [
{
"name": "coded 1000.1 desc",
"code": 1000.1
},
{
"name": "coded 2000.1 desc",
"code": 2000.2
},
{
"name": "coded 3000.1 desc",
"code": 3000.3000000000002
}
],
"mergePolicy": "esriMPTDefaultValue",
"splitPolicy": "esriSPTDefaultValue"
}
]
}