Contents

init(key:ascending:comparator:)

Creates a sort descriptor with a specified string key path and ordering, and a comparator block.

Declaration

init(key: String?, ascending: Bool, comparator cmptr: @escaping  Comparator)

Parameters

  • key:

    The property key for performing a comparison.

    For information about key paths, see 10000107i.

  • ascending:

    True if the receiver specifies sorting in ascending order; otherwise, False.

  • cmptr:

    A comparator block.

Return Value

A sort descriptor that initializes with the specified key, ordering, and comparator.

See Also

Creating a Sort Descriptor