Instance Method

sort(using:)

Sorts the receiving ordered set using a given array of sort descriptors.

Declaration

func sort(using sortDescriptors: [NSSortDescriptor])

Parameters

sortDescriptors

An array containing the NSSortDescriptor objects to use to sort the receiving ordered set’s contents.

Discussion

See NSSortDescriptor for additional information.

See Also

Sorting Entries

func sort(comparator: (Any, Any) -> ComparisonResult)

Sorts the mutable ordered set using the comparison method specified by the comparator block.

func sort(options: NSSortOptions, usingComparator: (Any, Any) -> ComparisonResult)

Sorts the mutable ordered set using the specified options and the comparison method specified by a given comparator block.

func sortRange(NSRange, options: NSSortOptions, usingComparator: (Any, Any) -> ComparisonResult)

Sorts the specified range of the mutable ordered set using the specified options and the comparison method specified by a given comparator block.

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