playbackCoordinator(_:identifierFor:)
Returns an identifier for a player item.
Declaration
optional func playbackCoordinator(_ coordinator: AVPlayerPlaybackCoordinator, identifierFor playerItem: AVPlayerItem) -> StringParameters
- coordinator:
The object coordinating playback.
- playerItem:
The player item to return an identifier for.
Return Value
An identifier string.
Discussion
A coordinator calls this method to identify the items that its player object plays.
Implement this method to enable the coordinator to establish the identity of items that have different URLs. For example, two participants may play the same item, but one plays the item from a remote host and the other from a local version on a device.
If you don’t implement this method, the coordinator derives an identifier from the item’s asset.