Package com.google.android.exoplayer2

## Class ForwardingPlayer

- java.lang.Object
- - com.google.android.exoplayer2.ForwardingPlayer

- All Implemented Interfaces:
    `Player`

      public class ForwardingPlayer
      extends Object
      implements Player

  A `Player` that forwards operations to another `Player`. Applications can use this class to suppress or modify specific operations, by overriding the respective methods.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface com.google.android.exoplayer2.Player

      `Player.Command, Player.Commands, Player.DiscontinuityReason, Player.Event, Player.EventListener, Player.Events, Player.Listener, Player.MediaItemTransitionReason, Player.PlaybackSuppressionReason, Player.PlayWhenReadyChangeReason, Player.PositionInfo, Player.RepeatMode, Player.State, Player.TimelineChangeReason`

  - ### Field Summary

    - ### Fields inherited from interface com.google.android.exoplayer2.Player

      `COMMAND_ADJUST_DEVICE_VOLUME, COMMAND_CHANGE_MEDIA_ITEMS, COMMAND_GET_AUDIO_ATTRIBUTES, COMMAND_GET_CURRENT_MEDIA_ITEM, COMMAND_GET_DEVICE_VOLUME, COMMAND_GET_MEDIA_ITEMS_METADATA, COMMAND_GET_TEXT, COMMAND_GET_TIMELINE, COMMAND_GET_VOLUME, COMMAND_INVALID, COMMAND_PLAY_PAUSE, COMMAND_PREPARE_STOP, COMMAND_SEEK_BACK, COMMAND_SEEK_FORWARD, COMMAND_SEEK_IN_CURRENT_WINDOW, COMMAND_SEEK_TO_DEFAULT_POSITION, COMMAND_SEEK_TO_NEXT, COMMAND_SEEK_TO_NEXT_WINDOW, COMMAND_SEEK_TO_PREVIOUS, COMMAND_SEEK_TO_PREVIOUS_WINDOW, COMMAND_SEEK_TO_WINDOW, COMMAND_SET_DEVICE_VOLUME, COMMAND_SET_MEDIA_ITEMS_METADATA, COMMAND_SET_REPEAT_MODE, COMMAND_SET_SHUFFLE_MODE, COMMAND_SET_SPEED_AND_PITCH, COMMAND_SET_VIDEO_SURFACE, COMMAND_SET_VOLUME, DISCONTINUITY_REASON_AUTO_TRANSITION, DISCONTINUITY_REASON_INTERNAL, DISCONTINUITY_REASON_REMOVE, DISCONTINUITY_REASON_SEEK, DISCONTINUITY_REASON_SEEK_ADJUSTMENT, DISCONTINUITY_REASON_SKIP, EVENT_AVAILABLE_COMMANDS_CHANGED, EVENT_IS_LOADING_CHANGED, EVENT_IS_PLAYING_CHANGED, EVENT_MAX_SEEK_TO_PREVIOUS_POSITION_CHANGED, EVENT_MEDIA_ITEM_TRANSITION, EVENT_MEDIA_METADATA_CHANGED, EVENT_PLAY_WHEN_READY_CHANGED, EVENT_PLAYBACK_PARAMETERS_CHANGED, EVENT_PLAYBACK_STATE_CHANGED, EVENT_PLAYBACK_SUPPRESSION_REASON_CHANGED, EVENT_PLAYER_ERROR, EVENT_PLAYLIST_METADATA_CHANGED, EVENT_POSITION_DISCONTINUITY, EVENT_REPEAT_MODE_CHANGED, EVENT_SEEK_BACK_INCREMENT_CHANGED, EVENT_SEEK_FORWARD_INCREMENT_CHANGED, EVENT_SHUFFLE_MODE_ENABLED_CHANGED, EVENT_STATIC_METADATA_CHANGED, EVENT_TIMELINE_CHANGED, EVENT_TRACKS_CHANGED, MEDIA_ITEM_TRANSITION_REASON_AUTO, MEDIA_ITEM_TRANSITION_REASON_PLAYLIST_CHANGED, MEDIA_ITEM_TRANSITION_REASON_REPEAT, MEDIA_ITEM_TRANSITION_REASON_SEEK, PLAY_WHEN_READY_CHANGE_REASON_AUDIO_BECOMING_NOISY, PLAY_WHEN_READY_CHANGE_REASON_AUDIO_FOCUS_LOSS, PLAY_WHEN_READY_CHANGE_REASON_END_OF_MEDIA_ITEM, PLAY_WHEN_READY_CHANGE_REASON_REMOTE, PLAY_WHEN_READY_CHANGE_REASON_USER_REQUEST, PLAYBACK_SUPPRESSION_REASON_NONE, PLAYBACK_SUPPRESSION_REASON_TRANSIENT_AUDIO_FOCUS_LOSS, REPEAT_MODE_ALL, REPEAT_MODE_OFF, REPEAT_MODE_ONE, STATE_BUFFERING, STATE_ENDED, STATE_IDLE, STATE_READY, TIMELINE_CHANGE_REASON_PLAYLIST_CHANGED, TIMELINE_CHANGE_REASON_SOURCE_UPDATE`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `ForwardingPlayer​(Player player)` | Creates a new instance that forwards all operations to `player`.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `addListener​(Player.EventListener listener)` | Deprecated.
    `void` | `addListener​(Player.Listener listener)` | Registers a listener to receive all events from the player.
    `void` | `addMediaItem​(int index, MediaItem mediaItem)` | Adds a media item at the given index of the playlist.
    `void` | `addMediaItem​(MediaItem mediaItem)` | Adds a media item to the end of the playlist.
    `void` | `addMediaItems​(int index, List<MediaItem> mediaItems)` | Adds a list of media items at the given index of the playlist.
    `void` | `addMediaItems​(List<MediaItem> mediaItems)` | Adds a list of media items to the end of the playlist.
    `void` | `clearMediaItems()` | Clears the playlist.
    `void` | `clearVideoSurface()` | Clears any `Surface`, `SurfaceHolder`, `SurfaceView` or `TextureView` currently set on the player.
    `void` | `clearVideoSurface​(Surface surface)` | Clears the `Surface` onto which video is being rendered if it matches the one passed.
    `void` | `clearVideoSurfaceHolder​(SurfaceHolder surfaceHolder)` | Clears the `SurfaceHolder` that holds the `Surface` onto which video is being rendered if it matches the one passed.
    `void` | `clearVideoSurfaceView​(SurfaceView surfaceView)` | Clears the `SurfaceView` onto which video is being rendered if it matches the one passed.
    `void` | `clearVideoTextureView​(TextureView textureView)` | Clears the `TextureView` onto which video is being rendered if it matches the one passed.
    `void` | `decreaseDeviceVolume()` | Decreases the volume of the device.
    `Looper` | `getApplicationLooper()` | Returns the `Looper` associated with the application thread that's used to access the player and on which player events are received.
    `AudioAttributes` | `getAudioAttributes()` | Returns the attributes for audio playback.
    `Player.Commands` | `getAvailableCommands()` | Returns the player's currently available `Player.Commands`.
    `int` | `getBufferedPercentage()` | Returns an estimate of the percentage in the current content window or ad up to which data is buffered, or 0 if no estimate is available.
    `long` | `getBufferedPosition()` | Returns an estimate of the position in the current content window or ad up to which data is buffered, in milliseconds.
    `long` | `getContentBufferedPosition()` | If `Player.isPlayingAd()` returns `true`, returns an estimate of the content position in the current content window up to which data is buffered, in milliseconds.
    `long` | `getContentDuration()` | If `Player.isPlayingAd()` returns `true`, returns the duration of the current content window in milliseconds, or `C.TIME_UNSET` if the duration is not known.
    `long` | `getContentPosition()` | If `Player.isPlayingAd()` returns `true`, returns the content position that will be played once all ads in the ad group have finished playing, in milliseconds.
    `int` | `getCurrentAdGroupIndex()` | If `Player.isPlayingAd()` returns true, returns the index of the ad group in the period currently being played.
    `int` | `getCurrentAdIndexInAdGroup()` | If `Player.isPlayingAd()` returns true, returns the index of the ad in its ad group.
    `List<Cue>` | `getCurrentCues()` | Returns the current `Cues`.
    `long` | `getCurrentLiveOffset()` | Returns the offset of the current playback position from the live edge in milliseconds, or `C.TIME_UNSET` if the current window `isn't live` or the offset is unknown.
    `Object` | `getCurrentManifest()` | Returns the current manifest.
    `MediaItem` | `getCurrentMediaItem()` | Returns the media item of the current window in the timeline.
    `int` | `getCurrentPeriodIndex()` | Returns the index of the period currently being played.
    `long` | `getCurrentPosition()` | Returns the playback position in the current content window or ad, in milliseconds, or the prospective position in milliseconds if the `current timeline` is empty.
    `List<Metadata>` | `getCurrentStaticMetadata()` | Deprecated.
    `Timeline` | `getCurrentTimeline()` | Returns the current `Timeline`.
    `TrackGroupArray` | `getCurrentTrackGroups()` | Returns the available track groups.
    `TrackSelectionArray` | `getCurrentTrackSelections()` | Returns the current track selections.
    `int` | `getCurrentWindowIndex()` | Returns the index of the current `window` in the `timeline`, or the prospective window index if the `current timeline` is empty.
    `DeviceInfo` | `getDeviceInfo()` | Gets the device information.
    `int` | `getDeviceVolume()` | Gets the current volume of the device.
    `long` | `getDuration()` | Returns the duration of the current content window or ad in milliseconds, or `C.TIME_UNSET` if the duration is not known.
    `int` | `getMaxSeekToPreviousPosition()` | Returns the maximum position for which `Player.seekToPrevious()` seeks to the previous window, in milliseconds.
    `MediaItem` | `getMediaItemAt​(int index)` | Returns the `MediaItem` at the given index.
    `int` | `getMediaItemCount()` | Returns the number of `media items` in the playlist.
    `MediaMetadata` | `getMediaMetadata()` | Returns the current combined `MediaMetadata`, or `MediaMetadata.EMPTY` if not supported.
    `int` | `getNextWindowIndex()` | Returns the index of the window that will be played if `Player.seekToNextWindow()` is called, which may depend on the current repeat mode and whether shuffle mode is enabled.
    `PlaybackParameters` | `getPlaybackParameters()` | Returns the currently active playback parameters.
    `int` | `getPlaybackState()` | Returns the current `playback state` of the player.
    `int` | `getPlaybackSuppressionReason()` | Returns the reason why playback is suppressed even though `Player.getPlayWhenReady()` is `true`, or `Player.PLAYBACK_SUPPRESSION_REASON_NONE` if playback is not suppressed.
    `PlaybackException` | `getPlayerError()` | Returns the error that caused playback to fail.
    `MediaMetadata` | `getPlaylistMetadata()` | Returns the playlist `MediaMetadata`, as set by `Player.setPlaylistMetadata(MediaMetadata)`, or `MediaMetadata.EMPTY` if not supported.
    `boolean` | `getPlayWhenReady()` | Whether playback will proceed when `Player.getPlaybackState()` == `Player.STATE_READY`.
    `int` | `getPreviousWindowIndex()` | Returns the index of the window that will be played if `Player.seekToPreviousWindow()` is called, which may depend on the current repeat mode and whether shuffle mode is enabled.
    `int` | `getRepeatMode()` | Returns the current `Player.RepeatMode` used for playback.
    `long` | `getSeekBackIncrement()` | Returns the `Player.seekBack()` increment.
    `long` | `getSeekForwardIncrement()` | Returns the `Player.seekForward()` increment.
    `boolean` | `getShuffleModeEnabled()` | Returns whether shuffling of windows is enabled.
    `long` | `getTotalBufferedDuration()` | Returns an estimate of the total buffered duration from the current position, in milliseconds.
    `VideoSize` | `getVideoSize()` | Gets the size of the video.
    `float` | `getVolume()` | Returns the audio volume, with 0 being silence and 1 being unity gain (signal unchanged).
    `Player` | `getWrappedPlayer()` | Returns the `Player` to which operations are forwarded.
    `boolean` | `hasNext()` | Deprecated.
    `boolean` | `hasNextWindow()` | Returns whether a next window exists, which may depend on the current repeat mode and whether shuffle mode is enabled.
    `boolean` | `hasPrevious()` | Deprecated.
    `boolean` | `hasPreviousWindow()` | Returns whether a previous window exists, which may depend on the current repeat mode and whether shuffle mode is enabled.
    `void` | `increaseDeviceVolume()` | Increases the volume of the device.
    `boolean` | `isCommandAvailable​(int command)` | Returns whether the provided `Player.Command` is available.
    `boolean` | `isCurrentWindowDynamic()` | Returns whether the current window is dynamic, or `false` if the `Timeline` is empty.
    `boolean` | `isCurrentWindowLive()` | Returns whether the current window is live, or `false` if the `Timeline` is empty.
    `boolean` | `isCurrentWindowSeekable()` | Returns whether the current window is seekable, or `false` if the `Timeline` is empty.
    `boolean` | `isDeviceMuted()` | Gets whether the device is muted or not.
    `boolean` | `isLoading()` | Whether the player is currently loading the source.
    `boolean` | `isPlaying()` | Returns whether the player is playing, i.e.
    `boolean` | `isPlayingAd()` | Returns whether the player is currently playing an ad.
    `void` | `moveMediaItem​(int currentIndex, int newIndex)` | Moves the media item at the current index to the new index.
    `void` | `moveMediaItems​(int fromIndex, int toIndex, int newIndex)` | Moves the media item range to the new index.
    `void` | `next()` | Deprecated.
    `void` | `pause()` | Pauses playback.
    `void` | `play()` | Resumes playback as soon as `Player.getPlaybackState()` == `Player.STATE_READY`.
    `void` | `prepare()` | Prepares the player.
    `void` | `previous()` | Deprecated.
    `void` | `release()` | Releases the player.
    `void` | `removeListener​(Player.EventListener listener)` | Deprecated.
    `void` | `removeListener​(Player.Listener listener)` | Unregister a listener registered through `Player.addListener(Listener)`.
    `void` | `removeMediaItem​(int index)` | Removes the media item at the given index of the playlist.
    `void` | `removeMediaItems​(int fromIndex, int toIndex)` | Removes a range of media items from the playlist.
    `void` | `seekBack()` | Seeks back in the current window by `Player.getSeekBackIncrement()` milliseconds.
    `void` | `seekForward()` | Seeks forward in the current window by `Player.getSeekForwardIncrement()` milliseconds.
    `void` | `seekTo​(int windowIndex, long positionMs)` | Seeks to a position specified in milliseconds in the specified window.
    `void` | `seekTo​(long positionMs)` | Seeks to a position specified in milliseconds in the current window.
    `void` | `seekToDefaultPosition()` | Seeks to the default position associated with the current window.
    `void` | `seekToDefaultPosition​(int windowIndex)` | Seeks to the default position associated with the specified window.
    `void` | `seekToNext()` | Seeks to a later position in the current or next window (if available).
    `void` | `seekToNextWindow()` | Seeks to the default position of the next window, which may depend on the current repeat mode and whether shuffle mode is enabled.
    `void` | `seekToPrevious()` | Seeks to an earlier position in the current or previous window (if available).
    `void` | `seekToPreviousWindow()` | Seeks to the default position of the previous window, which may depend on the current repeat mode and whether shuffle mode is enabled.
    `void` | `setDeviceMuted​(boolean muted)` | Sets the mute state of the device.
    `void` | `setDeviceVolume​(int volume)` | Sets the volume of the device.
    `void` | `setMediaItem​(MediaItem mediaItem)` | Clears the playlist, adds the specified `MediaItem` and resets the position to the default position.
    `void` | `setMediaItem​(MediaItem mediaItem, boolean resetPosition)` | Clears the playlist and adds the specified `MediaItem`.
    `void` | `setMediaItem​(MediaItem mediaItem, long startPositionMs)` | Clears the playlist and adds the specified `MediaItem`.
    `void` | `setMediaItems​(List<MediaItem> mediaItems)` | Clears the playlist, adds the specified `MediaItems` and resets the position to the default position.
    `void` | `setMediaItems​(List<MediaItem> mediaItems, boolean resetPosition)` | Clears the playlist and adds the specified `MediaItems`.
    `void` | `setMediaItems​(List<MediaItem> mediaItems, int startWindowIndex, long startPositionMs)` | Clears the playlist and adds the specified `MediaItems`.
    `void` | `setPlaybackParameters​(PlaybackParameters playbackParameters)` | Attempts to set the playback parameters.
    `void` | `setPlaybackSpeed​(float speed)` | Changes the rate at which playback occurs.
    `void` | `setPlaylistMetadata​(MediaMetadata mediaMetadata)` | Sets the playlist `MediaMetadata`.
    `void` | `setPlayWhenReady​(boolean playWhenReady)` | Sets whether playback should proceed when `Player.getPlaybackState()` == `Player.STATE_READY`.
    `void` | `setRepeatMode​(int repeatMode)` | Sets the `Player.RepeatMode` to be used for playback.
    `void` | `setShuffleModeEnabled​(boolean shuffleModeEnabled)` | Sets whether shuffling of windows is enabled.
    `void` | `setVideoSurface​(Surface surface)` | Sets the `Surface` onto which video will be rendered.
    `void` | `setVideoSurfaceHolder​(SurfaceHolder surfaceHolder)` | Sets the `SurfaceHolder` that holds the `Surface` onto which video will be rendered.
    `void` | `setVideoSurfaceView​(SurfaceView surfaceView)` | Sets the `SurfaceView` onto which video will be rendered.
    `void` | `setVideoTextureView​(TextureView textureView)` | Sets the `TextureView` onto which video will be rendered.
    `void` | `setVolume​(float audioVolume)` | Sets the audio volume, with 0 being silence and 1 being unity gain (signal unchanged).
    `void` | `stop()` | Stops playback without resetting the player.
    `void` | `stop​(boolean reset)` | Deprecated.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ForwardingPlayer

          public ForwardingPlayer​(Player player)

      Creates a new instance that forwards all operations to `player`.

  - ### Method Detail

    - #### getApplicationLooper

          public Looper getApplicationLooper()

      Description copied from interface: `Player`
      Returns the `Looper` associated with the application thread that's used to access the player and on which player events are received.
      Specified by:
        `getApplicationLooper` in interface `Player`

    - #### addListener

          @Deprecated
          public void addListener​(Player.EventListener listener)

      Deprecated.
      Description copied from interface: `Player`
      Registers a listener to receive events from the player.

      The listener's methods will be called on the thread that was used to construct the player. However, if the thread used to construct the player does not have a `Looper`, then the listener will be called on the main thread.

      Specified by:
        `addListener` in interface `Player`
      Parameters:
        `listener` - The listener to register.

    - #### addListener

          public void addListener​(Player.Listener listener)

      Description copied from interface: `Player`
      Registers a listener to receive all events from the player.

      The listener's methods will be called on the thread that was used to construct the player. However, if the thread used to construct the player does not have a `Looper`, then the listener will be called on the main thread.

      Specified by:
        `addListener` in interface `Player`
      Parameters:
        `listener` - The listener to register.

    - #### removeListener

          @Deprecated
          public void removeListener​(Player.EventListener listener)

      Deprecated.
      Description copied from interface: `Player`
      Unregister a listener registered through `Player.addListener(EventListener)`. The listener will no longer receive events from the player.
      Specified by:
        `removeListener` in interface `Player`
      Parameters:
        `listener` - The listener to unregister.

    - #### removeListener

          public void removeListener​(Player.Listener listener)

      Description copied from interface: `Player`
      Unregister a listener registered through `Player.addListener(Listener)`. The listener will no longer receive events.
      Specified by:
        `removeListener` in interface `Player`
      Parameters:
        `listener` - The listener to unregister.

    - #### setMediaItems

          public void setMediaItems​(List<MediaItem> mediaItems)

      Description copied from interface: `Player`
      Clears the playlist, adds the specified `MediaItems` and resets the position to the default position.
      Specified by:
        `setMediaItems` in interface `Player`
      Parameters:
        `mediaItems` - The new `MediaItems`.

    - #### setMediaItems

          public void setMediaItems​(List<MediaItem> mediaItems,
                                    boolean resetPosition)

      Description copied from interface: `Player`
      Clears the playlist and adds the specified `MediaItems`.
      Specified by:
        `setMediaItems` in interface `Player`
      Parameters:
        `mediaItems` - The new `MediaItems`.
        `resetPosition` - Whether the playback position should be reset to the default position in the first `Timeline.Window`. If false, playback will start from the position defined by `Player.getCurrentWindowIndex()` and `Player.getCurrentPosition()`.

    - #### setMediaItems

          public void setMediaItems​(List<MediaItem> mediaItems,
                                    int startWindowIndex,
                                    long startPositionMs)

      Description copied from interface: `Player`
      Clears the playlist and adds the specified `MediaItems`.
      Specified by:
        `setMediaItems` in interface `Player`
      Parameters:
        `mediaItems` - The new `MediaItems`.
        `startWindowIndex` - The window index to start playback from. If `C.INDEX_UNSET` is passed, the current position is not reset.
        `startPositionMs` - The position in milliseconds to start playback from. If `C.TIME_UNSET` is passed, the default position of the given window is used. In any case, if `startWindowIndex` is set to `C.INDEX_UNSET`, this parameter is ignored and the position is not reset at all.

    - #### setMediaItem

          public void setMediaItem​(MediaItem mediaItem)

      Description copied from interface: `Player`
      Clears the playlist, adds the specified `MediaItem` and resets the position to the default position.
      Specified by:
        `setMediaItem` in interface `Player`
      Parameters:
        `mediaItem` - The new `MediaItem`.

    - #### setMediaItem

          public void setMediaItem​(MediaItem mediaItem,
                                   long startPositionMs)

      Description copied from interface: `Player`
      Clears the playlist and adds the specified `MediaItem`.
      Specified by:
        `setMediaItem` in interface `Player`
      Parameters:
        `mediaItem` - The new `MediaItem`.
        `startPositionMs` - The position in milliseconds to start playback from.

    - #### setMediaItem

          public void setMediaItem​(MediaItem mediaItem,
                                   boolean resetPosition)

      Description copied from interface: `Player`
      Clears the playlist and adds the specified `MediaItem`.
      Specified by:
        `setMediaItem` in interface `Player`
      Parameters:
        `mediaItem` - The new `MediaItem`.
        `resetPosition` - Whether the playback position should be reset to the default position. If false, playback will start from the position defined by `Player.getCurrentWindowIndex()` and `Player.getCurrentPosition()`.

    - #### addMediaItem

          public void addMediaItem​(MediaItem mediaItem)

      Description copied from interface: `Player`
      Adds a media item to the end of the playlist.
      Specified by:
        `addMediaItem` in interface `Player`
      Parameters:
        `mediaItem` - The `MediaItem` to add.

    - #### addMediaItem

          public void addMediaItem​(int index,
                                   MediaItem mediaItem)

      Description copied from interface: `Player`
      Adds a media item at the given index of the playlist.
      Specified by:
        `addMediaItem` in interface `Player`
      Parameters:
        `index` - The index at which to add the media item. If the index is larger than the size of the playlist, the media item is added to the end of the playlist.
        `mediaItem` - The `MediaItem` to add.

    - #### addMediaItems

          public void addMediaItems​(List<MediaItem> mediaItems)

      Description copied from interface: `Player`
      Adds a list of media items to the end of the playlist.
      Specified by:
        `addMediaItems` in interface `Player`
      Parameters:
        `mediaItems` - The `MediaItems` to add.

    - #### addMediaItems

          public void addMediaItems​(int index,
                                    List<MediaItem> mediaItems)

      Description copied from interface: `Player`
      Adds a list of media items at the given index of the playlist.
      Specified by:
        `addMediaItems` in interface `Player`
      Parameters:
        `index` - The index at which to add the media items. If the index is larger than the size of the playlist, the media items are added to the end of the playlist.
        `mediaItems` - The `MediaItems` to add.

    - #### moveMediaItem

          public void moveMediaItem​(int currentIndex,
                                    int newIndex)

      Description copied from interface: `Player`
      Moves the media item at the current index to the new index.
      Specified by:
        `moveMediaItem` in interface `Player`
      Parameters:
        `currentIndex` - The current index of the media item to move.
        `newIndex` - The new index of the media item. If the new index is larger than the size of the playlist the item is moved to the end of the playlist.

    - #### moveMediaItems

          public void moveMediaItems​(int fromIndex,
                                     int toIndex,
                                     int newIndex)

      Description copied from interface: `Player`
      Moves the media item range to the new index.
      Specified by:
        `moveMediaItems` in interface `Player`
      Parameters:
        `fromIndex` - The start of the range to move.
        `toIndex` - The first item not to be included in the range (exclusive).
        `newIndex` - The new index of the first media item of the range. If the new index is larger than the size of the remaining playlist after removing the range, the range is moved to the end of the playlist.

    - #### removeMediaItem

          public void removeMediaItem​(int index)

      Description copied from interface: `Player`
      Removes the media item at the given index of the playlist.
      Specified by:
        `removeMediaItem` in interface `Player`
      Parameters:
        `index` - The index at which to remove the media item.

    - #### removeMediaItems

          public void removeMediaItems​(int fromIndex,
                                       int toIndex)

      Description copied from interface: `Player`
      Removes a range of media items from the playlist.
      Specified by:
        `removeMediaItems` in interface `Player`
      Parameters:
        `fromIndex` - The index at which to start removing media items.
        `toIndex` - The index of the first item to be kept (exclusive). If the index is larger than the size of the playlist, media items to the end of the playlist are removed.

    - #### clearMediaItems

          public void clearMediaItems()

      Description copied from interface: `Player`
      Clears the playlist.
      Specified by:
        `clearMediaItems` in interface `Player`

    - #### isCommandAvailable

          public boolean isCommandAvailable​(@Command
                                            int command)

      Description copied from interface: `Player`
      Returns whether the provided `Player.Command` is available.

      This method does not execute the command.

      Executing a command that is not available (for example, calling `Player.seekToNextWindow()` if `Player.COMMAND_SEEK_TO_NEXT_WINDOW` is unavailable) will neither throw an exception nor generate a `Player.getPlayerError()` player error}.

      `Player.COMMAND_SEEK_TO_PREVIOUS_WINDOW` and `Player.COMMAND_SEEK_TO_NEXT_WINDOW` are unavailable if there is no such `MediaItem`.

      Specified by:
        `isCommandAvailable` in interface `Player`
      Parameters:
        `command` - A `Player.Command`.
      Returns:
        Whether the `Player.Command` is available.
      See Also:
        `Player.Listener.onAvailableCommandsChanged(Commands)`

    - #### getAvailableCommands

          public Player.Commands getAvailableCommands()

      Description copied from interface: `Player`
      Returns the player's currently available `Player.Commands`.

      The returned `Player.Commands` are not updated when available commands change. Use `Player.Listener.onAvailableCommandsChanged(Commands)` to get an update when the available commands change.

      Executing a command that is not available (for example, calling `Player.seekToNextWindow()` if `Player.COMMAND_SEEK_TO_NEXT_WINDOW` is unavailable) will neither throw an exception nor generate a `Player.getPlayerError()` player error}.

      `Player.COMMAND_SEEK_TO_PREVIOUS_WINDOW` and `Player.COMMAND_SEEK_TO_NEXT_WINDOW` are unavailable if there is no such `MediaItem`.

      Specified by:
        `getAvailableCommands` in interface `Player`
      Returns:
        The currently available `Player.Commands`.
      See Also:
        `Player.Listener.onAvailableCommandsChanged(com.google.android.exoplayer2.Player.Commands)`

    - #### prepare

          public void prepare()

      Description copied from interface: `Player`
      Prepares the player.
      Specified by:
        `prepare` in interface `Player`

    - #### getPlaybackState

          public int getPlaybackState()

      Description copied from interface: `Player`
      Returns the current `playback state` of the player.
      Specified by:
        `getPlaybackState` in interface `Player`
      Returns:
        The current `playback state`.
      See Also:
        `Player.Listener.onPlaybackStateChanged(int)`

    - #### getPlaybackSuppressionReason

          public int getPlaybackSuppressionReason()

      Description copied from interface: `Player`
      Returns the reason why playback is suppressed even though `Player.getPlayWhenReady()` is `true`, or `Player.PLAYBACK_SUPPRESSION_REASON_NONE` if playback is not suppressed.
      Specified by:
        `getPlaybackSuppressionReason` in interface `Player`
      Returns:
        The current `playback suppression reason`.
      See Also:
        `Player.Listener.onPlaybackSuppressionReasonChanged(int)`

    - #### isPlaying

          public boolean isPlaying()

      Description copied from interface: `Player`
      Returns whether the player is playing, i.e. `Player.getCurrentPosition()` is advancing.

      If `false`, then at least one of the following is true:

      - The `playback state` is not `ready`.
      - There is no `intention to play`.
      - Playback is `suppressed for other reasons`.
      Specified by:
        `isPlaying` in interface `Player`
      Returns:
        Whether the player is playing.
      See Also:
        `Player.Listener.onIsPlayingChanged(boolean)`

    - #### getPlayerError

          @Nullable
          public PlaybackException getPlayerError()

      Description copied from interface: `Player`
      Returns the error that caused playback to fail. This is the same error that will have been reported via `Player.Listener.onPlayerError(PlaybackException)` at the time of failure. It can be queried using this method until the player is re-prepared.

      Note that this method will always return `null` if `Player.getPlaybackState()` is not `Player.STATE_IDLE`.

      Specified by:
        `getPlayerError` in interface `Player`
      Returns:
        The error, or `null`.
      See Also:
        `Player.Listener.onPlayerError(PlaybackException)`

    - #### play

          public void play()

      Description copied from interface: `Player`
      Resumes playback as soon as `Player.getPlaybackState()` == `Player.STATE_READY`. Equivalent to `setPlayWhenReady(true)`.
      Specified by:
        `play` in interface `Player`

    - #### pause

          public void pause()

      Description copied from interface: `Player`
      Pauses playback. Equivalent to `setPlayWhenReady(false)`.
      Specified by:
        `pause` in interface `Player`

    - #### setPlayWhenReady

          public void setPlayWhenReady​(boolean playWhenReady)

      Description copied from interface: `Player`
      Sets whether playback should proceed when `Player.getPlaybackState()` == `Player.STATE_READY`.

      If the player is already in the ready state then this method pauses and resumes playback.

      Specified by:
        `setPlayWhenReady` in interface `Player`
      Parameters:
        `playWhenReady` - Whether playback should proceed when ready.

    - #### getPlayWhenReady

          public boolean getPlayWhenReady()

      Description copied from interface: `Player`
      Whether playback will proceed when `Player.getPlaybackState()` == `Player.STATE_READY`.
      Specified by:
        `getPlayWhenReady` in interface `Player`
      Returns:
        Whether playback will proceed when ready.
      See Also:
        `Player.Listener.onPlayWhenReadyChanged(boolean, int)`

    - #### setRepeatMode

          public void setRepeatMode​(@RepeatMode
                                    int repeatMode)

      Description copied from interface: `Player`
      Sets the `Player.RepeatMode` to be used for playback.
      Specified by:
        `setRepeatMode` in interface `Player`
      Parameters:
        `repeatMode` - The repeat mode.

    - #### getRepeatMode

          public int getRepeatMode()

      Description copied from interface: `Player`
      Returns the current `Player.RepeatMode` used for playback.
      Specified by:
        `getRepeatMode` in interface `Player`
      Returns:
        The current repeat mode.
      See Also:
        `Player.Listener.onRepeatModeChanged(int)`

    - #### setShuffleModeEnabled

          public void setShuffleModeEnabled​(boolean shuffleModeEnabled)

      Description copied from interface: `Player`
      Sets whether shuffling of windows is enabled.
      Specified by:
        `setShuffleModeEnabled` in interface `Player`
      Parameters:
        `shuffleModeEnabled` - Whether shuffling is enabled.

    - #### getShuffleModeEnabled

          public boolean getShuffleModeEnabled()

      Description copied from interface: `Player`
      Returns whether shuffling of windows is enabled.
      Specified by:
        `getShuffleModeEnabled` in interface `Player`
      See Also:
        `Player.Listener.onShuffleModeEnabledChanged(boolean)`

    - #### isLoading

          public boolean isLoading()

      Description copied from interface: `Player`
      Whether the player is currently loading the source.
      Specified by:
        `isLoading` in interface `Player`
      Returns:
        Whether the player is currently loading the source.
      See Also:
        `Player.Listener.onIsLoadingChanged(boolean)`

    - #### seekToDefaultPosition

          public void seekToDefaultPosition()

      Description copied from interface: `Player`
      Seeks to the default position associated with the current window. The position can depend on the type of media being played. For live streams it will typically be the live edge of the window. For other streams it will typically be the start of the window.
      Specified by:
        `seekToDefaultPosition` in interface `Player`

    - #### seekToDefaultPosition

          public void seekToDefaultPosition​(int windowIndex)

      Description copied from interface: `Player`
      Seeks to the default position associated with the specified window. The position can depend on the type of media being played. For live streams it will typically be the live edge of the window. For other streams it will typically be the start of the window.
      Specified by:
        `seekToDefaultPosition` in interface `Player`
      Parameters:
        `windowIndex` - The index of the window whose associated default position should be seeked to.

    - #### seekTo

          public void seekTo​(long positionMs)

      Description copied from interface: `Player`
      Seeks to a position specified in milliseconds in the current window.
      Specified by:
        `seekTo` in interface `Player`
      Parameters:
        `positionMs` - The seek position in the current window, or `C.TIME_UNSET` to seek to the window's default position.

    - #### seekTo

          public void seekTo​(int windowIndex,
                             long positionMs)

      Description copied from interface: `Player`
      Seeks to a position specified in milliseconds in the specified window.
      Specified by:
        `seekTo` in interface `Player`
      Parameters:
        `windowIndex` - The index of the window.
        `positionMs` - The seek position in the specified window, or `C.TIME_UNSET` to seek to the window's default position.

    - #### getSeekBackIncrement

          public long getSeekBackIncrement()

      Description copied from interface: `Player`
      Returns the `Player.seekBack()` increment.
      Specified by:
        `getSeekBackIncrement` in interface `Player`
      Returns:
        The seek back increment, in milliseconds.
      See Also:
        `Player.Listener.onSeekBackIncrementChanged(long)`

    - #### seekBack

          public void seekBack()

      Description copied from interface: `Player`
      Seeks back in the current window by `Player.getSeekBackIncrement()` milliseconds.
      Specified by:
        `seekBack` in interface `Player`

    - #### getSeekForwardIncrement

          public long getSeekForwardIncrement()

      Description copied from interface: `Player`
      Returns the `Player.seekForward()` increment.
      Specified by:
        `getSeekForwardIncrement` in interface `Player`
      Returns:
        The seek forward increment, in milliseconds.
      See Also:
        `Player.Listener.onSeekForwardIncrementChanged(long)`

    - #### seekForward

          public void seekForward()

      Description copied from interface: `Player`
      Seeks forward in the current window by `Player.getSeekForwardIncrement()` milliseconds.
      Specified by:
        `seekForward` in interface `Player`

    - #### hasPrevious

          @Deprecated
          public boolean hasPrevious()

      Deprecated.
      Specified by:
        `hasPrevious` in interface `Player`

    - #### hasPreviousWindow

          public boolean hasPreviousWindow()

      Description copied from interface: `Player`
      Returns whether a previous window exists, which may depend on the current repeat mode and whether shuffle mode is enabled.

      Note: When the repeat mode is `Player.REPEAT_MODE_ONE`, this method behaves the same as when the current repeat mode is `Player.REPEAT_MODE_OFF`. See `Player.REPEAT_MODE_ONE` for more details.

      Specified by:
        `hasPreviousWindow` in interface `Player`

    - #### previous

          @Deprecated
          public void previous()

      Deprecated.
      Specified by:
        `previous` in interface `Player`

    - #### seekToPreviousWindow

          public void seekToPreviousWindow()

      Description copied from interface: `Player`
      Seeks to the default position of the previous window, which may depend on the current repeat mode and whether shuffle mode is enabled. Does nothing if `Player.hasPreviousWindow()` is `false`.

      Note: When the repeat mode is `Player.REPEAT_MODE_ONE`, this method behaves the same as when the current repeat mode is `Player.REPEAT_MODE_OFF`. See `Player.REPEAT_MODE_ONE` for more details.

      Specified by:
        `seekToPreviousWindow` in interface `Player`

    - #### seekToPrevious

          public void seekToPrevious()

      Description copied from interface: `Player`
      Seeks to an earlier position in the current or previous window (if available). More precisely:
      - If the timeline is empty or seeking is not possible, does nothing.
      - Otherwise, if the current window is `live` and `unseekable`, then:
        - If `a previous window exists`, seeks to the default position of the previous window.
        - Otherwise, does nothing.
      - Otherwise, if `a previous window exists` and the `current position` is less than `Player.getMaxSeekToPreviousPosition()`, seeks to the default position of the previous window.
      - Otherwise, seeks to 0 in the current window.
      Specified by:
        `seekToPrevious` in interface `Player`

    - #### getMaxSeekToPreviousPosition

          public int getMaxSeekToPreviousPosition()

      Description copied from interface: `Player`
      Returns the maximum position for which `Player.seekToPrevious()` seeks to the previous window, in milliseconds.
      Specified by:
        `getMaxSeekToPreviousPosition` in interface `Player`
      Returns:
        The maximum seek to previous position, in milliseconds.
      See Also:
        `Player.EventListener.onMaxSeekToPreviousPositionChanged(int)`

    - #### hasNext

          @Deprecated
          public boolean hasNext()

      Deprecated.
      Specified by:
        `hasNext` in interface `Player`

    - #### hasNextWindow

          public boolean hasNextWindow()

      Description copied from interface: `Player`
      Returns whether a next window exists, which may depend on the current repeat mode and whether shuffle mode is enabled.

      Note: When the repeat mode is `Player.REPEAT_MODE_ONE`, this method behaves the same as when the current repeat mode is `Player.REPEAT_MODE_OFF`. See `Player.REPEAT_MODE_ONE` for more details.

      Specified by:
        `hasNextWindow` in interface `Player`

    - #### next

          @Deprecated
          public void next()

      Deprecated.
      Specified by:
        `next` in interface `Player`

    - #### seekToNextWindow

          public void seekToNextWindow()

      Description copied from interface: `Player`
      Seeks to the default position of the next window, which may depend on the current repeat mode and whether shuffle mode is enabled. Does nothing if `Player.hasNextWindow()` is `false`.

      Note: When the repeat mode is `Player.REPEAT_MODE_ONE`, this method behaves the same as when the current repeat mode is `Player.REPEAT_MODE_OFF`. See `Player.REPEAT_MODE_ONE` for more details.

      Specified by:
        `seekToNextWindow` in interface `Player`

    - #### seekToNext

          public void seekToNext()

      Description copied from interface: `Player`
      Seeks to a later position in the current or next window (if available). More precisely:
      - If the timeline is empty or seeking is not possible, does nothing.
      - Otherwise, if `a next window exists`, seeks to the default position of the next window.
      - Otherwise, if the current window is `live` and has not ended, seeks to the live edge of the current window.
      - Otherwise, does nothing.
      Specified by:
        `seekToNext` in interface `Player`

    - #### setPlaybackParameters

          public void setPlaybackParameters​(PlaybackParameters playbackParameters)

      Description copied from interface: `Player`
      Attempts to set the playback parameters. Passing `PlaybackParameters.DEFAULT` resets the player to the default, which means there is no speed or pitch adjustment.

      Playback parameters changes may cause the player to buffer. `Player.Listener.onPlaybackParametersChanged(PlaybackParameters)` will be called whenever the currently active playback parameters change.

      Specified by:
        `setPlaybackParameters` in interface `Player`
      Parameters:
        `playbackParameters` - The playback parameters.

    - #### setPlaybackSpeed

          public void setPlaybackSpeed​(float speed)

      Description copied from interface: `Player`
      Changes the rate at which playback occurs. The pitch is not changed.

      This is equivalent to `setPlaybackParameters(getPlaybackParameters().withSpeed(speed))`.

      Specified by:
        `setPlaybackSpeed` in interface `Player`
      Parameters:
        `speed` - The linear factor by which playback will be sped up. Must be higher than 0. 1 is normal speed, 2 is twice as fast, 0.5 is half normal speed...

    - #### getPlaybackParameters

          public PlaybackParameters getPlaybackParameters()

      Description copied from interface: `Player`
      Returns the currently active playback parameters.
      Specified by:
        `getPlaybackParameters` in interface `Player`
      See Also:
        `Player.Listener.onPlaybackParametersChanged(PlaybackParameters)`

    - #### stop

          public void stop()

      Description copied from interface: `Player`
      Stops playback without resetting the player. Use `Player.pause()` rather than this method if the intention is to pause playback.

      Calling this method will cause the playback state to transition to `Player.STATE_IDLE`. The player instance can still be used, and `Player.release()` must still be called on the player if it's no longer required.

      Calling this method does not clear the playlist, reset the playback position or the playback error.

      Specified by:
        `stop` in interface `Player`

    - #### stop

          @Deprecated
          public void stop​(boolean reset)

      Deprecated.
      Specified by:
        `stop` in interface `Player`

    - #### release

          public void release()

      Description copied from interface: `Player`
      Releases the player. This method must be called when the player is no longer required. The player must not be used after calling this method.
      Specified by:
        `release` in interface `Player`

    - #### getCurrentTrackGroups

          public TrackGroupArray getCurrentTrackGroups()

      Description copied from interface: `Player`
      Returns the available track groups.
      Specified by:
        `getCurrentTrackGroups` in interface `Player`
      See Also:
        `Player.Listener.onTracksChanged(TrackGroupArray, TrackSelectionArray)`

    - #### getCurrentTrackSelections

          public TrackSelectionArray getCurrentTrackSelections()

      Description copied from interface: `Player`
      Returns the current track selections.

      A concrete implementation may include null elements if it has a fixed number of renderer components, wishes to report a TrackSelection for each of them, and has one or more renderer components that is not assigned any selected tracks.

      Specified by:
        `getCurrentTrackSelections` in interface `Player`
      See Also:
        `Player.Listener.onTracksChanged(TrackGroupArray, TrackSelectionArray)`

    - #### getCurrentStaticMetadata

          @Deprecated
          public List<Metadata> getCurrentStaticMetadata()

      Deprecated.
      Specified by:
        `getCurrentStaticMetadata` in interface `Player`

    - #### getMediaMetadata

          public MediaMetadata getMediaMetadata()

      Description copied from interface: `Player`
      Returns the current combined `MediaMetadata`, or `MediaMetadata.EMPTY` if not supported.

      This `MediaMetadata` is a combination of the `MediaItem.mediaMetadata` and the static and dynamic metadata from the `track selections' formats` and `MetadataOutput.onMetadata(Metadata)`.

      Specified by:
        `getMediaMetadata` in interface `Player`

    - #### getPlaylistMetadata

          public MediaMetadata getPlaylistMetadata()

      Description copied from interface: `Player`
      Returns the playlist `MediaMetadata`, as set by `Player.setPlaylistMetadata(MediaMetadata)`, or `MediaMetadata.EMPTY` if not supported.
      Specified by:
        `getPlaylistMetadata` in interface `Player`

    - #### setPlaylistMetadata

          public void setPlaylistMetadata​(MediaMetadata mediaMetadata)

      Description copied from interface: `Player`
      Sets the playlist `MediaMetadata`.
      Specified by:
        `setPlaylistMetadata` in interface `Player`

    - #### getCurrentManifest

          @Nullable
          public Object getCurrentManifest()

      Description copied from interface: `Player`
      Returns the current manifest. The type depends on the type of media being played. May be null.
      Specified by:
        `getCurrentManifest` in interface `Player`

    - #### getCurrentTimeline

          public Timeline getCurrentTimeline()

      Description copied from interface: `Player`
      Returns the current `Timeline`. Never null, but may be empty.
      Specified by:
        `getCurrentTimeline` in interface `Player`
      See Also:
        `Player.Listener.onTimelineChanged(Timeline, int)`

    - #### getCurrentPeriodIndex

          public int getCurrentPeriodIndex()

      Description copied from interface: `Player`
      Returns the index of the period currently being played.
      Specified by:
        `getCurrentPeriodIndex` in interface `Player`

    - #### getCurrentWindowIndex

          public int getCurrentWindowIndex()

      Description copied from interface: `Player`
      Returns the index of the current `window` in the `timeline`, or the prospective window index if the `current timeline` is empty.
      Specified by:
        `getCurrentWindowIndex` in interface `Player`

    - #### getNextWindowIndex

          public int getNextWindowIndex()

      Description copied from interface: `Player`
      Returns the index of the window that will be played if `Player.seekToNextWindow()` is called, which may depend on the current repeat mode and whether shuffle mode is enabled. Returns `C.INDEX_UNSET` if `Player.hasNextWindow()` is `false`.

      Note: When the repeat mode is `Player.REPEAT_MODE_ONE`, this method behaves the same as when the current repeat mode is `Player.REPEAT_MODE_OFF`. See `Player.REPEAT_MODE_ONE` for more details.

      Specified by:
        `getNextWindowIndex` in interface `Player`

    - #### getPreviousWindowIndex

          public int getPreviousWindowIndex()

      Description copied from interface: `Player`
      Returns the index of the window that will be played if `Player.seekToPreviousWindow()` is called, which may depend on the current repeat mode and whether shuffle mode is enabled. Returns `C.INDEX_UNSET` if `Player.hasPreviousWindow()` is `false`.

      Note: When the repeat mode is `Player.REPEAT_MODE_ONE`, this method behaves the same as when the current repeat mode is `Player.REPEAT_MODE_OFF`. See `Player.REPEAT_MODE_ONE` for more details.

      Specified by:
        `getPreviousWindowIndex` in interface `Player`

    - #### getCurrentMediaItem

          @Nullable
          public MediaItem getCurrentMediaItem()

      Description copied from interface: `Player`
      Returns the media item of the current window in the timeline. May be null if the timeline is empty.
      Specified by:
        `getCurrentMediaItem` in interface `Player`
      See Also:
        `Player.Listener.onMediaItemTransition(MediaItem, int)`

    - #### getMediaItemCount

          public int getMediaItemCount()

      Description copied from interface: `Player`
      Returns the number of `media items` in the playlist.
      Specified by:
        `getMediaItemCount` in interface `Player`

    - #### getMediaItemAt

          public MediaItem getMediaItemAt​(int index)

      Description copied from interface: `Player`
      Returns the `MediaItem` at the given index.
      Specified by:
        `getMediaItemAt` in interface `Player`

    - #### getDuration

          public long getDuration()

      Description copied from interface: `Player`
      Returns the duration of the current content window or ad in milliseconds, or `C.TIME_UNSET` if the duration is not known.
      Specified by:
        `getDuration` in interface `Player`

    - #### getCurrentPosition

          public long getCurrentPosition()

      Description copied from interface: `Player`
      Returns the playback position in the current content window or ad, in milliseconds, or the prospective position in milliseconds if the `current timeline` is empty.
      Specified by:
        `getCurrentPosition` in interface `Player`

    - #### getBufferedPosition

          public long getBufferedPosition()

      Description copied from interface: `Player`
      Returns an estimate of the position in the current content window or ad up to which data is buffered, in milliseconds.
      Specified by:
        `getBufferedPosition` in interface `Player`

    - #### getBufferedPercentage

          public int getBufferedPercentage()

      Description copied from interface: `Player`
      Returns an estimate of the percentage in the current content window or ad up to which data is buffered, or 0 if no estimate is available.
      Specified by:
        `getBufferedPercentage` in interface `Player`

    - #### getTotalBufferedDuration

          public long getTotalBufferedDuration()

      Description copied from interface: `Player`
      Returns an estimate of the total buffered duration from the current position, in milliseconds. This includes pre-buffered data for subsequent ads and windows.
      Specified by:
        `getTotalBufferedDuration` in interface `Player`

    - #### isCurrentWindowDynamic

          public boolean isCurrentWindowDynamic()

      Description copied from interface: `Player`
      Returns whether the current window is dynamic, or `false` if the `Timeline` is empty.
      Specified by:
        `isCurrentWindowDynamic` in interface `Player`
      See Also:
        `Timeline.Window.isDynamic`

    - #### isCurrentWindowLive

          public boolean isCurrentWindowLive()

      Description copied from interface: `Player`
      Returns whether the current window is live, or `false` if the `Timeline` is empty.
      Specified by:
        `isCurrentWindowLive` in interface `Player`
      See Also:
        `Timeline.Window.isLive()`

    - #### getCurrentLiveOffset

          public long getCurrentLiveOffset()

      Description copied from interface: `Player`
      Returns the offset of the current playback position from the live edge in milliseconds, or `C.TIME_UNSET` if the current window `isn't live` or the offset is unknown.

      The offset is calculated as `currentTime - playbackPosition`, so should usually be positive.

      Note that this offset may rely on an accurate local time, so this method may return an incorrect value if the difference between system clock and server clock is unknown.

      Specified by:
        `getCurrentLiveOffset` in interface `Player`

    - #### isCurrentWindowSeekable

          public boolean isCurrentWindowSeekable()

      Description copied from interface: `Player`
      Returns whether the current window is seekable, or `false` if the `Timeline` is empty.
      Specified by:
        `isCurrentWindowSeekable` in interface `Player`
      See Also:
        `Timeline.Window.isSeekable`

    - #### isPlayingAd

          public boolean isPlayingAd()

      Description copied from interface: `Player`
      Returns whether the player is currently playing an ad.
      Specified by:
        `isPlayingAd` in interface `Player`

    - #### getCurrentAdGroupIndex

          public int getCurrentAdGroupIndex()

      Description copied from interface: `Player`
      If `Player.isPlayingAd()` returns true, returns the index of the ad group in the period currently being played. Returns `C.INDEX_UNSET` otherwise.
      Specified by:
        `getCurrentAdGroupIndex` in interface `Player`

    - #### getCurrentAdIndexInAdGroup

          public int getCurrentAdIndexInAdGroup()

      Description copied from interface: `Player`
      If `Player.isPlayingAd()` returns true, returns the index of the ad in its ad group. Returns `C.INDEX_UNSET` otherwise.
      Specified by:
        `getCurrentAdIndexInAdGroup` in interface `Player`

    - #### getContentDuration

          public long getContentDuration()

      Description copied from interface: `Player`
      If `Player.isPlayingAd()` returns `true`, returns the duration of the current content window in milliseconds, or `C.TIME_UNSET` if the duration is not known. If there is no ad playing, the returned duration is the same as that returned by `Player.getDuration()`.
      Specified by:
        `getContentDuration` in interface `Player`

    - #### getContentPosition

          public long getContentPosition()

      Description copied from interface: `Player`
      If `Player.isPlayingAd()` returns `true`, returns the content position that will be played once all ads in the ad group have finished playing, in milliseconds. If there is no ad playing, the returned position is the same as that returned by `Player.getCurrentPosition()`.
      Specified by:
        `getContentPosition` in interface `Player`

    - #### getContentBufferedPosition

          public long getContentBufferedPosition()

      Description copied from interface: `Player`
      If `Player.isPlayingAd()` returns `true`, returns an estimate of the content position in the current content window up to which data is buffered, in milliseconds. If there is no ad playing, the returned position is the same as that returned by `Player.getBufferedPosition()`.
      Specified by:
        `getContentBufferedPosition` in interface `Player`

    - #### getAudioAttributes

          public AudioAttributes getAudioAttributes()

      Description copied from interface: `Player`
      Returns the attributes for audio playback.
      Specified by:
        `getAudioAttributes` in interface `Player`

    - #### setVolume

          public void setVolume​(float audioVolume)

      Description copied from interface: `Player`
      Sets the audio volume, with 0 being silence and 1 being unity gain (signal unchanged).
      Specified by:
        `setVolume` in interface `Player`
      Parameters:
        `audioVolume` - Linear output gain to apply to all audio channels.

    - #### getVolume

          public float getVolume()

      Description copied from interface: `Player`
      Returns the audio volume, with 0 being silence and 1 being unity gain (signal unchanged).
      Specified by:
        `getVolume` in interface `Player`
      Returns:
        The linear gain applied to all audio channels.

    - #### getVideoSize

          public VideoSize getVideoSize()

      Description copied from interface: `Player`
      Gets the size of the video.

      The video's width and height are `0` if there is no video or its size has not been determined yet.

      Specified by:
        `getVideoSize` in interface `Player`
      See Also:
        `Player.Listener.onVideoSizeChanged(VideoSize)`

    - #### clearVideoSurface

          public void clearVideoSurface()

      Description copied from interface: `Player`
      Clears any `Surface`, `SurfaceHolder`, `SurfaceView` or `TextureView` currently set on the player.
      Specified by:
        `clearVideoSurface` in interface `Player`

    - #### clearVideoSurface

          public void clearVideoSurface​(@Nullable
                                        Surface surface)

      Description copied from interface: `Player`
      Clears the `Surface` onto which video is being rendered if it matches the one passed. Else does nothing.
      Specified by:
        `clearVideoSurface` in interface `Player`
      Parameters:
        `surface` - The surface to clear.

    - #### setVideoSurface

          public void setVideoSurface​(@Nullable
                                      Surface surface)

      Description copied from interface: `Player`
      Sets the `Surface` onto which video will be rendered. The caller is responsible for tracking the lifecycle of the surface, and must clear the surface by calling `setVideoSurface(null)` if the surface is destroyed.

      If the surface is held by a `SurfaceView`, `TextureView` or `SurfaceHolder` then it's recommended to use `Player.setVideoSurfaceView(SurfaceView)`, `Player.setVideoTextureView(TextureView)` or `Player.setVideoSurfaceHolder(SurfaceHolder)` rather than this method, since passing the holder allows the player to track the lifecycle of the surface automatically.

      Specified by:
        `setVideoSurface` in interface `Player`
      Parameters:
        `surface` - The `Surface`.

    - #### setVideoSurfaceHolder

          public void setVideoSurfaceHolder​(@Nullable
                                            SurfaceHolder surfaceHolder)

      Description copied from interface: `Player`
      Sets the `SurfaceHolder` that holds the `Surface` onto which video will be rendered. The player will track the lifecycle of the surface automatically.

      The thread that calls the `SurfaceHolder.Callback` methods must be the thread associated with `Player.getApplicationLooper()`.

      Specified by:
        `setVideoSurfaceHolder` in interface `Player`
      Parameters:
        `surfaceHolder` - The surface holder.

    - #### clearVideoSurfaceHolder

          public void clearVideoSurfaceHolder​(@Nullable
                                              SurfaceHolder surfaceHolder)

      Description copied from interface: `Player`
      Clears the `SurfaceHolder` that holds the `Surface` onto which video is being rendered if it matches the one passed. Else does nothing.
      Specified by:
        `clearVideoSurfaceHolder` in interface `Player`
      Parameters:
        `surfaceHolder` - The surface holder to clear.

    - #### setVideoSurfaceView

          public void setVideoSurfaceView​(@Nullable
                                          SurfaceView surfaceView)

      Description copied from interface: `Player`
      Sets the `SurfaceView` onto which video will be rendered. The player will track the lifecycle of the surface automatically.

      The thread that calls the `SurfaceHolder.Callback` methods must be the thread associated with `Player.getApplicationLooper()`.

      Specified by:
        `setVideoSurfaceView` in interface `Player`
      Parameters:
        `surfaceView` - The surface view.

    - #### clearVideoSurfaceView

          public void clearVideoSurfaceView​(@Nullable
                                            SurfaceView surfaceView)

      Description copied from interface: `Player`
      Clears the `SurfaceView` onto which video is being rendered if it matches the one passed. Else does nothing.
      Specified by:
        `clearVideoSurfaceView` in interface `Player`
      Parameters:
        `surfaceView` - The texture view to clear.

    - #### setVideoTextureView

          public void setVideoTextureView​(@Nullable
                                          TextureView textureView)

      Description copied from interface: `Player`
      Sets the `TextureView` onto which video will be rendered. The player will track the lifecycle of the surface automatically.

      The thread that calls the `TextureView.SurfaceTextureListener` methods must be the thread associated with `Player.getApplicationLooper()`.

      Specified by:
        `setVideoTextureView` in interface `Player`
      Parameters:
        `textureView` - The texture view.

    - #### clearVideoTextureView

          public void clearVideoTextureView​(@Nullable
                                            TextureView textureView)

      Description copied from interface: `Player`
      Clears the `TextureView` onto which video is being rendered if it matches the one passed. Else does nothing.
      Specified by:
        `clearVideoTextureView` in interface `Player`
      Parameters:
        `textureView` - The texture view to clear.

    - #### getCurrentCues

          public List<Cue> getCurrentCues()

      Description copied from interface: `Player`
      Returns the current `Cues`. This list may be empty.
      Specified by:
        `getCurrentCues` in interface `Player`

    - #### getDeviceInfo

          public DeviceInfo getDeviceInfo()

      Description copied from interface: `Player`
      Gets the device information.
      Specified by:
        `getDeviceInfo` in interface `Player`

    - #### getDeviceVolume

          public int getDeviceVolume()

      Description copied from interface: `Player`
      Gets the current volume of the device.

      For devices with `local playback`, the volume returned by this method varies according to the current `stream type`. The stream type is determined by `AudioAttributes.usage` which can be converted to stream type with `Util.getStreamTypeForAudioUsage(int)`.

      For devices with `remote playback`, the volume of the remote device is returned.

      Specified by:
        `getDeviceVolume` in interface `Player`

    - #### isDeviceMuted

          public boolean isDeviceMuted()

      Description copied from interface: `Player`
      Gets whether the device is muted or not.
      Specified by:
        `isDeviceMuted` in interface `Player`

    - #### setDeviceVolume

          public void setDeviceVolume​(int volume)

      Description copied from interface: `Player`
      Sets the volume of the device.
      Specified by:
        `setDeviceVolume` in interface `Player`
      Parameters:
        `volume` - The volume to set.

    - #### increaseDeviceVolume

          public void increaseDeviceVolume()

      Description copied from interface: `Player`
      Increases the volume of the device.
      Specified by:
        `increaseDeviceVolume` in interface `Player`

    - #### decreaseDeviceVolume

          public void decreaseDeviceVolume()

      Description copied from interface: `Player`
      Decreases the volume of the device.
      Specified by:
        `decreaseDeviceVolume` in interface `Player`

    - #### setDeviceMuted

          public void setDeviceMuted​(boolean muted)

      Description copied from interface: `Player`
      Sets the mute state of the device.
      Specified by:
        `setDeviceMuted` in interface `Player`

    - #### getWrappedPlayer

          public Player getWrappedPlayer()

      Returns the `Player` to which operations are forwarded.