ArcGIS Runtime SDK for iOS: AGSPolygonBarrier Class Reference
ArcGIS Runtime SDK for iOS  100.15
AGSPolygonBarrier Class Reference

Description

A polygon barrier to constrain routes.

Instances of this class represent a polygon barrier that can be used to constrain routes generated by AGSRouteTask or service areas generated by AGSServiceAreaTask.

Barriers serve to temporarily restrict, add impedance (cost) to, and scale impedance on parts of the transportation network.

Since
100
See also
http://desktop.arcgis.com/en/arcmap/latest/extensions/network-analyst/barriers.htm
Inheritance diagram for AGSPolygonBarrier:
AGSObject

Instance Methods

(instancetype) - initWithPolygon:
 
(double) - scaleFactorForCostAttribute:
 
(void) - setScaleFactor:forCostAttribute:
 

Class Methods

(instancetype) + barrierWithPolygon:
 

Properties

NSInteger barrierID
 
AGSPolygongeometry
 
NSString * name
 
AGSBarrierType type
 

Method Documentation

◆ barrierWithPolygon:

+ (instancetype) barrierWithPolygon: (AGSPolygon *)  polygon

Initialize the polygon barrier with provided geometry

Parameters
polygondefining the shape and location of the barrier
Returns
Initialized polygon barrier
Since
100

◆ initWithPolygon:

- (instancetype) initWithPolygon: (AGSPolygon *)  polygon

Initialize the polygon barrier with provided geometry

Parameters
polygondefining the shape and location of the barrier
Returns
Initialized polygon barrier
Since
100

◆ scaleFactorForCostAttribute:

- (double) scaleFactorForCostAttribute: (NSString *)  attributeName

The scale factor for a cost attribute of the barrier. The factor can be used to increase or decrease the cost of traveling across the barrier

Parameters
attributeNamename of the cost attribute
Returns
scale factor
Since
100.2

◆ setScaleFactor:forCostAttribute:

- (void) setScaleFactor: (double)  scaleFactor
forCostAttribute: (NSString *)  attributeName 

Sets the scale factor for a cost attribute of the barrier. The factor can be used to increase or decrease the cost of traveling across the barrier

Parameters
scaleFactorby which to increase or decrease the cost
attributeNamename of the cost attribute
Since
100.2

Property Documentation

◆ barrierID

◆ geometry

- (AGSPolygon*) geometry
readwritenonatomicstrong

The shape and location of the barrier

Since
100

◆ name

- (NSString*) name
readwritenonatomiccopy

The name of the polygon barrier.

Since
100.3

◆ type

- (AGSBarrierType) type
readwritenonatomicassign

The type of the barrier, whether it fully restricts travel accross it, or merely increases the cost of travel

Since
100