Contents

sortedArray(using:)

Returns an array of the ordered set’s elements sorted as specified by a given array of sort descriptors.

Declaration

func sortedArray(using sortDescriptors: [NSSortDescriptor]) -> [Any]

Parameters

Return Value

An NSArray containing the ordered set’s elements sorted as specified by sortDescriptors.

Discussion

The first descriptor specifies the primary key path to be used in sorting the ordered set’s elements. Any subsequent descriptors are used to further refine sorting of objects with duplicate values. See NSSortDescriptor for additional information.

See Also

Creating a Sorted Array