Contents

canPerform(_:)

Returns whether the collection supports the specified editing operation.

Declaration

func canPerform(_ anOperation: PHCollectionEditOperation) -> Bool

Parameters

  • anOperation:

    A bit mask of editing operations to be tested.

Return Value

true if the asset supports the specified editing operation; otherwise, false.

Discussion

If an asset collection or collection list supports editing, you can create a PHAssetCollectionChangeRequest or PHCollectionListChangeRequest object inside a PHPhotoLibrary change block to submit a change.

See Also

Determining Collection Capabilities