AGSClosestFacilityTask Class Reference
Description
Instances of this class represent tasks that can find the find closest facilities around any location on a network. Finding the closest hospital to an accident, the closest police cars to a crime scene, and the closest store to a customer's address are all examples of closest facility problems. When finding closest facilities, you can specify how many to find and whether the direction of travel is toward or away from them. Once you've found the closest facilities, you can display the best route to or from them, return the travel cost for each route, and display directions to each facility. Additionally, you can specify an impedance cutoff beyond which the task should not search for a facility. For instance, you can set up a closest facility problem to search for hospitals within 15 minutes' drive time of the site of an accident. Any hospitals that take longer than 15 minutes to reach will not be included in the results
A closest facility task needs a URL to a REST resource that represents a Closest Facility layer in a Network Analyst service.
- Availability:
- This feature is only available with services from ArcGIS Server 10.0 or above
- Since:
- 1.8
List of all members.
Member Function Documentation
+ (id) closestFacilityTaskWithURL: |
|
(NSURL *) |
url |
|
|
Initialize a new, autoreleased closest facility task with the given url.
- Parameters:
-
| url | The url of the closest facility layer. |
- Returns:
- A new, autoreleased closest facility task object.
- Since:
- 1.8
+ (id) closestFacilityTaskWithURL: |
|
(NSURL *) |
url |
credential: |
|
(AGSCredential *) |
cred | |
|
|
| | |
Initialize a new, autoreleased closest facility task with the given url and credential.
- Parameters:
-
| url | The url of the closest facility layer. |
| cred | The credential to be used to access the secured resource. |
- Returns:
- A new, autoreleased closest facility task object.
- Since:
- 1.8
- (id) initWithURL: |
|
(NSURL *) |
url |
|
|
Initialize the task.
- Parameters:
-
| url | URL to a task resource in the ArcGIS Server REST Services Directory. |
- Returns:
- A new task object.
- Since:
- 1.0
- (id) initWithURL: |
|
(NSURL *) |
url |
credential: |
|
(AGSCredential *) |
cred | |
|
|
| | |
Initialize the task with a URL and credential to a secured resource.
- Parameters:
-
| url | URL to a task resource in the ArcGIS Server REST Services Directory. |
| cred | AGSCredential used to access secure resource. |
- Returns:
- A new task object.
- Since:
- 1.0
- (NSOperation*) retrieveDefaultClosestFacilityTaskParameters |
|
|
|
|
Retrieves the default closest facility parameters as defined by the service.
- Returns:
NSOperation
for the request.
- Since:
- 1.8
Performs a closest facility operation with the given input parameters.
- Parameters:
-
| closestFacilityParams | The input parameters for the closest facility operation. |
- Returns:
NSOperation
for the current closest facility task.
- Since:
- 1.8
Property Documentation
The credential to be used to access secured resources.
- Since:
- 1.0
Reimplemented from <AGSSecuredResource>.
Delegate to be notified when the closest facility operation has completed or returned an error.
- Since:
- 1.8
- (NSURL*) URL [read, copy, inherited] |
URL to a task resource in the ArcGIS Server REST Services Directory.
- Since:
- 1.0