Hide Table of Contents
esri/dijit/util
esri/layer/pixelFilters
esri/process
esri/support
esri/workers
Class: StandardGeographyQueryTask

dojo.require("esri.tasks.geoenrichment.StandardGeographyQueryTask");

Description

(Added at v3.12)
(Currently in beta)
Geoenrichment helper task that returns standard geography IDs and features for the supported geographic levels in Canada, the United States and a number of European countries. For example, you can use this service to find the FIPS for the county of San Diego, which is 06073. You can then use this FIPS ID within the Geoenrichment service study area definition to get geometry and optional demographic data for the county.

Samples

Search for samples that use this class.

Constructors

NameSummary
new esri.tasks.geoenrichment.StandardGeographyQueryTask(url?)Creates a new instance of the StandardGeographyQueryTask class.

Methods

NameReturn typeSummary
execute(GeographyQuery)PromiseExecutes the StandardGeographyQueryTask.

Events

[ On Style Events | Connect Style Event ]
All On Style event listeners receive a single event object. Additionally, the event object also contains a 'target' property whose value is the object which fired the event.

Events

NameEvent ObjectSummary
error
{
  error: <Error>
}
Fires when an error occurs during the query.
execute-complete
{
  features: <FeatureSet>
}
Fires when the query successfully executes.
Constructor Details

new esri.tasks.geoenrichment.StandardGeographyQueryTask(url?)

Creates a new instance of the StandardGeographyQueryTask class.
Parameters:
<String> url Optional URL to the Geoenrichment server. Defaults to the World Geoenrichment Server (http://geoenrich.arcgis.com/arcgis/rest/services/World/GeoenrichmentServer) if a valid URL is not provided.
Method Details

execute(GeographyQuery)

Executes the StandardGeographyQueryTask. Fires the onExecuteComplete event when completed successfully, and the onError event if an error occurs.
Return type: Promise
Parameters:
<GeographyQueryBase> GeographyQuery Required See GeographyQuery or SubGeographyQuery classes for more details about available properties.
Event Details
[ On Style Events | Connect Style Event ]

error

Fires when an error occurs during the query.
Event Object Properties:
<Error> error Fires when an error occurs during the query.

execute-complete

Fires when the query successfully executes.
Event Object Properties:
<FeatureSet> features The FeatureSet returned from the query.
Show Modal