Instance Method

setArray:

Sets the receiving array’s elements to those in another given array.

Declaration

- (void)setArray:(NSArray<ObjectType> *)otherArray;

Parameters

otherArray

The array of objects with which to replace the receiving array’s content.

See Also

Replacing Objects

- replaceObjectAtIndex:withObject:

Replaces the object at index with anObject.

- setObject:atIndexedSubscript:

Replaces the object at the index with the new object, possibly adding the object.

- replaceObjectsAtIndexes:withObjects:

Replaces the objects in the receiving array at locations specified with the objects from a given array.

- replaceObjectsInRange:withObjectsFromArray:range:

Replaces the objects in the receiving array specified by one given range with the objects in another array specified by another range.

- replaceObjectsInRange:withObjectsFromArray:

Replaces the objects in the receiving array specified by a given range with all of the objects from a given array.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software