ArcGIS Runtime SDK for iOS
100.15
|
Mutable collection of parts of a multipart geometry builder.
Instances of this class represent a mutable collection of parts of a multipart geometry builder (AGSMultipartBuilder
). Not only is the collection modifiable, but it is made up of mutable parts and so the individual parts in the collection are also modifiable.
This class adopts NSFastEnumeration
which permits the collection to be enumerated conveniently using a for-in loop. For example -
This class also provides subscripting support. So you can access segments using the subscript syntax. For example -
AGSMultipartBuilder
for multipart geometry builders Instance Methods | |
(NSInteger) | - addPart: |
(NSArray< AGSMutablePart * > *) | - array |
(NSInteger) | - indexOfPart: |
(instancetype) | - initWithSpatialReference: |
(void) | - insertPart:atIndex: |
(AGSMutablePart *) | - objectAtIndexedSubscript: |
(AGSMutablePart *) | - partAtIndex: |
(AGSEnumerator *) | - partEnumerator |
(void) | - removeAllParts |
(void) | - removePartAtIndex: |
(void) | - setObject:atIndexedSubscript: |
(void) | - setPart:atIndex: |
Class Methods | |
(instancetype) | + partCollectionWithSpatialReference: |
Properties | |
NSInteger | count |
BOOL | isEmpty |
AGSSpatialReference * | spatialReference |
NSInteger | totalPointCount |
- (NSInteger) addPart: | (AGSMutablePart *) | part |
Add a part to the end of this collection.
part | to add. |
0
is the first position. - (NSArray<AGSMutablePart*>*) array |
Returns an array of parts.
- (NSInteger) indexOfPart: | (AGSMutablePart *) | part |
Returns the index of the specified part.
part | whose index needs to be located. |
- (instancetype) initWithSpatialReference: | (nullable AGSSpatialReference *) | spatialReference |
Initialize a collection with specified spatial reference. All parts that belong to this collection must have the same spatial reference, or if they don't have a spatial reference, it will be assumed that they contain coordinates that match this spatial reference.
spatialReference | of the collection. |
- (void) insertPart: | (AGSMutablePart *) | part | |
atIndex: | (NSInteger) | index | |
Insert a part at the specified position.
part | to insert. |
index | of desired position. 0 is the first position. |
- (AGSMutablePart*) objectAtIndexedSubscript: | (NSInteger) | idx |
Returns the part at the specified index. Supports accessing an individual part using array-style subscript expressions.
idx | An index within the bounds of the collection. |
- (AGSMutablePart*) partAtIndex: | (NSInteger) | index |
Returns the part at the specified index.
index | An index within the bounds of the collection. |
+ (instancetype) partCollectionWithSpatialReference: | (nullable AGSSpatialReference *) | spatialReference |
Create a new collection with specified spatial reference. All parts that belong to this collection must have the same spatial reference, or if they don't have a spatial reference, it will be assumed that they contain coordinates that match this spatial reference.
spatialReference | of the collection. |
- (AGSEnumerator*) partEnumerator |
Returns an enumerator object that lets you access each object in the part collection.
- (void) removeAllParts |
Remove all parts from this collection.
- (void) removePartAtIndex: | (NSInteger) | index |
Remove part at specified position.
index | of desired position. 0 is the first position. |
- (void) setObject: | (AGSMutablePart *) | obj | |
atIndexedSubscript: | (NSInteger) | idx | |
Sets the part at the specified index. Supports assigning an individual part using array-style subscript expressions. For example -
obj | part to set. |
idx | subscript index. |
- (void) setPart: | (AGSMutablePart *) | part | |
atIndex: | (NSInteger) | index | |
Replace existing part with the specified one.
part | to replace with. |
index | of part to replace. |
|
readnonatomicassign |
The number of parts in the collection.
|
readnonatomicassign |
Indicates whether the collection is empty or not.
|
readnonatomicstrong |
The spatial reference associated with parts in the collection. It specifies the coordinate system for each part's x & y coordinate values. All parts in this collection must have the same spatial reference, or if they don't have a spatial reference, it will be assumed that they contain coordinates that match this spatial reference.
|
readnonatomicassign |
The total number of points (vertices) across all parts of the geometry.