Contents

indexPath(for:)

Returns the index path of the specified item.

Declaration

func indexPath(for item: NSCollectionViewItem) -> IndexPath?

Parameters

  • item:

    The item whose index path you want to know.

Return Value

The item’s index path or nil if the item is not in the collection view.

See Also

Locating Items and Views