Interface AVPlaybackCoordinatorPlaybackControlDelegate


  • public interface AVPlaybackCoordinatorPlaybackControlDelegate
    [@protocol] AVPlaybackCoordinatorPlaybackControlDelegate A custom player implementation API-Since: 15.0
    • Method Detail

      • playbackCoordinatorDidIssueBufferingCommandCompletionHandler

        void playbackCoordinatorDidIssueBufferingCommandCompletionHandler​(@NotNull
                                                                          @NotNull AVDelegatingPlaybackCoordinator coordinator,
                                                                          @NotNull
                                                                          @NotNull AVDelegatingPlaybackCoordinatorBufferingCommand bufferingCommand,
                                                                          @NotNull
                                                                          @NotNull AVPlaybackCoordinatorPlaybackControlDelegate.Block_playbackCoordinatorDidIssueBufferingCommandCompletionHandler completionHandler)
        playbackCoordinator:didIssueBufferingCommand:completionHandler: Called by the coordinator to indicate that playback is expected to begin soon and the playback object should begin buffering. The coordinator issues this command when playback is currently paused and the coordinator is expecting playback to start soon. In response to this command, it is appropriate to update playback UI to indicate playback in a waiting state. The expected start can be cancelled by calling -[AVDelegatingPlaybackCoordinator coordinateRateChangeTo:0].
        Parameters:
        coordinator - The coordinator requesting buffering to begin.
        bufferingCommand - A buffering command object. See AVDelegatingPlaybackCoordinatorBufferingCommand. The receiver should verify that the command is still valid by inspecting the expectedCurrentItemIdentifier property before applying the command.
        completionHandler - The receiver must call the completion handler when done, either when the command has been handled succesfully or when the receiver has indicated its inability to handle the command by beginning a suspension with an appropriate reason. For buffering commands, the command should only be considered complete once the playback object is ready to receive a subsequent play command.
      • playbackCoordinatorDidIssuePauseCommandCompletionHandler

        void playbackCoordinatorDidIssuePauseCommandCompletionHandler​(@NotNull
                                                                      @NotNull AVDelegatingPlaybackCoordinator coordinator,
                                                                      @NotNull
                                                                      @NotNull AVDelegatingPlaybackCoordinatorPauseCommand pauseCommand,
                                                                      @NotNull
                                                                      @NotNull AVPlaybackCoordinatorPlaybackControlDelegate.Block_playbackCoordinatorDidIssuePauseCommandCompletionHandler completionHandler)
        playbackCoordinator:didIssuePauseCommand:completionHandler: Called by the coordinator to pause playback.
        Parameters:
        coordinator - The coordinator requesting playback to pause.
        pauseCommand - A pause command object. See AVDelegatingPlaybackCoordinatorPauseCommand. The receiver should verify that the command is still valid by inspecting the expectedCurrentItemIdentifier property before applying the command.
        completionHandler - The receiver must call the completion handler when done, either when the command has been handled succesfully or when the receiver has indicated its inability to handle the command by beginning a suspension with an appropriate reason. If the command's shouldBufferInAnticipationOfPlayback is YES, the completion handler should also only be called once the playback object is ready to receive a subsequent play command.
      • playbackCoordinatorDidIssuePlayCommandCompletionHandler

        void playbackCoordinatorDidIssuePlayCommandCompletionHandler​(@NotNull
                                                                     @NotNull AVDelegatingPlaybackCoordinator coordinator,
                                                                     @NotNull
                                                                     @NotNull AVDelegatingPlaybackCoordinatorPlayCommand playCommand,
                                                                     @NotNull
                                                                     @NotNull AVPlaybackCoordinatorPlaybackControlDelegate.Block_playbackCoordinatorDidIssuePlayCommandCompletionHandler completionHandler)
        playbackCoordinator:didIssuePlayCommand:completionHandler: Called by the coordinator to match the playback rate of the control delegate to the group, when the target rate is non-zero. The coordinator issues this command when the desired playback timeline has changed. This may mean that the rate has changed, but it can also mean that the anchor time has changed. Play commands are only issued when the desired playback rate is non-zero.
        Parameters:
        coordinator - The coordinator requesting a change in playback rate.
        playCommand - A play command object. See AVDelegatingPlaybackCoordinatorPlayCommand. The receiver should verify that the command is still valid by inspecting the expectedCurrentItemIdentifier property before applying the command.
        completionHandler - The receiver must call the completion handler when done, either when the command has been handled succesfully or when the receiver has indicated its inability to handle the command by beginning a suspension with an appropriate reason.
      • playbackCoordinatorDidIssueSeekCommandCompletionHandler

        void playbackCoordinatorDidIssueSeekCommandCompletionHandler​(@NotNull
                                                                     @NotNull AVDelegatingPlaybackCoordinator coordinator,
                                                                     @NotNull
                                                                     @NotNull AVDelegatingPlaybackCoordinatorSeekCommand seekCommand,
                                                                     @NotNull
                                                                     @NotNull AVPlaybackCoordinatorPlaybackControlDelegate.Block_playbackCoordinatorDidIssueSeekCommandCompletionHandler completionHandler)
        playbackCoordinator:didIssueSeekCommand:completionHandler: Called by the coordinator to seek to a new time. The coordinator issues this command when the playback object current time changes, potentially also pausing playback.
        Parameters:
        coordinator - The coordinator requesting the seek.
        seekCommand - A seek command object. See AVDelegatingPlaybackCoordinatorSeekCommand. The receiver should verify that the command is still valid by inspecting the expectedCurrentItemIdentifier property before applying the command.
        completionHandler - The receiver must call the completion handler when done, either when the command has been handled succesfully or when the receiver has indicated its inability to handle the command by beginning a suspension with an appropriate reason. If the command's shouldBufferInAnticipationOfPlayback is YES, the completion handler should also only be called once the playback object is ready to receive a subsequent play command.