Instance Method

playerViewController:didPresentInterstitialTimeRange:

Tells the delegate the player view controller has completed playing a range of interstitial content.

Declaration

- (void)playerViewController:(AVPlayerViewController *)playerViewController didPresentInterstitialTimeRange:(AVInterstitialTimeRange *)interstitial;

Parameters

playerViewController

The player view controller to which you’ve assigned the delegate.

interstitial

The time range of interstitial content that has finished playback.

Discussion

Interstitial content is material unrelated to the main content of a presentation that may have special playback options or requirements. For example, you can use this method to record when the user has viewed an advertisement, or to disable the player view controller’s requiresLinearPlayback property after presenting mandatory legal notices.

Use the interstitialTimeRanges property to identify time ranges for interstitial content in the AVPlayerItem object presented in the player view controller.

See Also

Responding to Interstitial Content Playback Events

- playerViewController:willPresentInterstitialTimeRange:

Tells the delegate the player view controller is about to begin playing a range of interstitial content.