ServiceAreaTask

AMD: require(["esri/tasks/ServiceAreaTask"], (ServiceAreaTask) => { /* code goes here */ });
ESM: import ServiceAreaTask from "@arcgis/core/tasks/ServiceAreaTask";
Class: esri/tasks/ServiceAreaTask
Inheritance: ServiceAreaTask Task Accessor
Since: ArcGIS API for JavaScript 4.0
Deprecated since version 4.20. Use serviceArea instead.

ServiceAreaTask helps you find service areas around any location on a network. A network service area is a region that encompasses all accessible streets (streets that are within a specified impedance). For instance, the 5-minute service area for a point includes all the streets that can be reached within five minutes from that point.

ServiceAreaTask, and other service area related classes, requires a service area layer. A service area layer is a layer of type esriNAServerServiceAreaLayer.

See also:

Constructors

new ServiceAreaTask(properties)
Parameter:
properties Object
optional

See the properties for a list of all the properties that may be passed into the constructor.

Property Overview

Any properties can be set, retrieved or listened to. See the Working with Properties topic.
Show inherited properties Hide inherited properties
Name Type Summary Class
Stringmore details

The name of the class.

more detailsAccessor
Stringmore details

The ArcGIS Server REST service URL (usually of a Feature Service Layer or Map Service Layer) for use in a task.

more detailsTask

Property Details

declaredClass Stringreadonly inherited
Since: ArcGIS API for JavaScript 4.7

The name of the class. The declared class name is formatted as esri.folder.className.

The ArcGIS Server REST service URL (usually of a Feature Service Layer or Map Service Layer) for use in a task.

Method Overview

Name Return Type Summary Class
Promise<ServiceAreaSolveResult>more details

Determines the service area based on a set of parameters.

more detailsServiceAreaTask

Method Details

solve(params, requestOptions){Promise<ServiceAreaSolveResult>}

Determines the service area based on a set of parameters.

Parameters:

The parameters needed to define the service area.

requestOptions Object
optional

Additional options to be used for the data request.

Returns:
Type Description
Promise<ServiceAreaSolveResult> When resolved, returns an instance of ServiceAreaSolveResult.

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.