Contents

forEach(_:)

Calls the given closure with an index and element of the array in the same order as a for-in loop.

Declaration

func forEach(_ body: (Int, xpc_object_t) throws -> Void) rethrows

Parameters

  • body:

    A closure that takes an index and an element of the sequence as parameters.

See Also

Iterating over an array’s elements