Package com.google.android.exoplayer2
Class ForwardingPlayer
- java.lang.Object
-
- com.google.android.exoplayer2.ForwardingPlayer
-
- All Implemented Interfaces:
Player
@Deprecated public class ForwardingPlayer extends Object implements Player
Deprecated.com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.google.android.exoplayer2.Player
Player.Command, Player.Commands, Player.DiscontinuityReason, Player.Event, 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_ADJUST_DEVICE_VOLUME_WITH_FLAGS, COMMAND_CHANGE_MEDIA_ITEMS, COMMAND_GET_AUDIO_ATTRIBUTES, COMMAND_GET_CURRENT_MEDIA_ITEM, COMMAND_GET_DEVICE_VOLUME, COMMAND_GET_MEDIA_ITEMS_METADATA, COMMAND_GET_METADATA, COMMAND_GET_TEXT, COMMAND_GET_TIMELINE, COMMAND_GET_TRACKS, COMMAND_GET_VOLUME, COMMAND_INVALID, COMMAND_PLAY_PAUSE, COMMAND_PREPARE, COMMAND_RELEASE, COMMAND_SEEK_BACK, COMMAND_SEEK_FORWARD, COMMAND_SEEK_IN_CURRENT_MEDIA_ITEM, COMMAND_SEEK_IN_CURRENT_WINDOW, COMMAND_SEEK_TO_DEFAULT_POSITION, COMMAND_SEEK_TO_MEDIA_ITEM, COMMAND_SEEK_TO_NEXT, COMMAND_SEEK_TO_NEXT_MEDIA_ITEM, COMMAND_SEEK_TO_NEXT_WINDOW, COMMAND_SEEK_TO_PREVIOUS, COMMAND_SEEK_TO_PREVIOUS_MEDIA_ITEM, COMMAND_SEEK_TO_PREVIOUS_WINDOW, COMMAND_SEEK_TO_WINDOW, COMMAND_SET_DEVICE_VOLUME, COMMAND_SET_DEVICE_VOLUME_WITH_FLAGS, COMMAND_SET_MEDIA_ITEM, COMMAND_SET_MEDIA_ITEMS_METADATA, COMMAND_SET_PLAYLIST_METADATA, COMMAND_SET_REPEAT_MODE, COMMAND_SET_SHUFFLE_MODE, COMMAND_SET_SPEED_AND_PITCH, COMMAND_SET_TRACK_SELECTION_PARAMETERS, COMMAND_SET_VIDEO_SURFACE, COMMAND_SET_VOLUME, COMMAND_STOP, DISCONTINUITY_REASON_AUTO_TRANSITION, DISCONTINUITY_REASON_INTERNAL, DISCONTINUITY_REASON_REMOVE, DISCONTINUITY_REASON_SEEK, DISCONTINUITY_REASON_SEEK_ADJUSTMENT, DISCONTINUITY_REASON_SKIP, EVENT_AUDIO_ATTRIBUTES_CHANGED, EVENT_AUDIO_SESSION_ID, EVENT_AVAILABLE_COMMANDS_CHANGED, EVENT_CUES, EVENT_DEVICE_INFO_CHANGED, EVENT_DEVICE_VOLUME_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_METADATA, 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_RENDERED_FIRST_FRAME, EVENT_REPEAT_MODE_CHANGED, EVENT_SEEK_BACK_INCREMENT_CHANGED, EVENT_SEEK_FORWARD_INCREMENT_CHANGED, EVENT_SHUFFLE_MODE_ENABLED_CHANGED, EVENT_SKIP_SILENCE_ENABLED_CHANGED, EVENT_SURFACE_SIZE_CHANGED, EVENT_TIMELINE_CHANGED, EVENT_TRACK_SELECTION_PARAMETERS_CHANGED, EVENT_TRACKS_CHANGED, EVENT_VIDEO_SIZE_CHANGED, EVENT_VOLUME_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_SUPPRESSED_TOO_LONG, PLAY_WHEN_READY_CHANGE_REASON_USER_REQUEST, PLAYBACK_SUPPRESSION_REASON_NONE, PLAYBACK_SUPPRESSION_REASON_TRANSIENT_AUDIO_FOCUS_LOSS, PLAYBACK_SUPPRESSION_REASON_UNSUITABLE_AUDIO_ROUTE, 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)
Deprecated.Creates a new instance that forwards all operations toplayer
.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addListener(Player.Listener listener)
Deprecated.CallsPlayer.addListener(Listener)
on the delegate.void
addMediaItem(int index, MediaItem mediaItem)
Deprecated.CallsPlayer.addMediaItem(int, MediaItem)
on the delegate.void
addMediaItem(MediaItem mediaItem)
Deprecated.CallsPlayer.addMediaItem(MediaItem)
on the delegate.void
addMediaItems(int index, List<MediaItem> mediaItems)
Deprecated.CallsPlayer.addMediaItems(int, List)
on the delegate.void
addMediaItems(List<MediaItem> mediaItems)
Deprecated.CallsPlayer.addMediaItems(List)
on the delegate.boolean
canAdvertiseSession()
Deprecated.CallsPlayer.canAdvertiseSession()
on the delegate and returns the result.void
clearMediaItems()
Deprecated.CallsPlayer.clearMediaItems()
on the delegate.void
clearVideoSurface()
Deprecated.CallsPlayer.clearVideoSurface()
on the delegate.void
clearVideoSurface(Surface surface)
Deprecated.CallsPlayer.clearVideoSurface(Surface)
on the delegate.void
clearVideoSurfaceHolder(SurfaceHolder surfaceHolder)
Deprecated.CallsPlayer.clearVideoSurfaceHolder(SurfaceHolder)
on the delegate.void
clearVideoSurfaceView(SurfaceView surfaceView)
Deprecated.CallsPlayer.clearVideoSurfaceView(SurfaceView)
on the delegate.void
clearVideoTextureView(TextureView textureView)
Deprecated.CallsPlayer.clearVideoTextureView(TextureView)
on the delegate.void
decreaseDeviceVolume()
Deprecated.UsedecreaseDeviceVolume(int)
instead.void
decreaseDeviceVolume(@com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.decreaseDeviceVolume(int)
on the delegate.Looper
getApplicationLooper()
Deprecated.CallsPlayer.getApplicationLooper()
on the delegate and returns the result.AudioAttributes
getAudioAttributes()
Deprecated.CallsPlayer.getAudioAttributes()
on the delegate and returns the result.Player.Commands
getAvailableCommands()
Deprecated.CallsPlayer.getAvailableCommands()
on the delegate and returns the result.int
getBufferedPercentage()
Deprecated.CallsPlayer.getBufferedPercentage()
on the delegate and returns the result.long
getBufferedPosition()
Deprecated.CallsPlayer.getBufferedPosition()
on the delegate and returns the result.long
getContentBufferedPosition()
Deprecated.CallsPlayer.getContentBufferedPosition()
on the delegate and returns the result.long
getContentDuration()
Deprecated.CallsPlayer.getContentDuration()
on the delegate and returns the result.long
getContentPosition()
Deprecated.CallsPlayer.getContentPosition()
on the delegate and returns the result.int
getCurrentAdGroupIndex()
Deprecated.CallsPlayer.getCurrentAdGroupIndex()
on the delegate and returns the result.int
getCurrentAdIndexInAdGroup()
Deprecated.CallsPlayer.getCurrentAdIndexInAdGroup()
on the delegate and returns the result.CueGroup
getCurrentCues()
Deprecated.CallsPlayer.getCurrentCues()
on the delegate and returns the result.long
getCurrentLiveOffset()
Deprecated.CallsPlayer.getCurrentLiveOffset()
on the delegate and returns the result.Object
getCurrentManifest()
Deprecated.CallsPlayer.getCurrentManifest()
on the delegate and returns the result.MediaItem
getCurrentMediaItem()
Deprecated.CallsPlayer.getCurrentMediaItem()
on the delegate and returns the result.int
getCurrentMediaItemIndex()
Deprecated.CallsPlayer.getCurrentMediaItemIndex()
on the delegate and returns the result.int
getCurrentPeriodIndex()
Deprecated.CallsPlayer.getCurrentPeriodIndex()
on the delegate and returns the result.long
getCurrentPosition()
Deprecated.CallsPlayer.getCurrentPosition()
on the delegate and returns the result.Timeline
getCurrentTimeline()
Deprecated.CallsPlayer.getCurrentTimeline()
on the delegate and returns the result.Tracks
getCurrentTracks()
Deprecated.CallsPlayer.getCurrentTracks()
on the delegate and returns the result.int
getCurrentWindowIndex()
Deprecated.UsegetCurrentMediaItemIndex()
instead.DeviceInfo
getDeviceInfo()
Deprecated.CallsPlayer.getDeviceInfo()
on the delegate and returns the result.int
getDeviceVolume()
Deprecated.CallsPlayer.getDeviceVolume()
on the delegate and returns the result.long
getDuration()
Deprecated.CallsPlayer.getDuration()
on the delegate and returns the result.long
getMaxSeekToPreviousPosition()
Deprecated.CallsPlayer.getMaxSeekToPreviousPosition()
on the delegate and returns the result.MediaItem
getMediaItemAt(int index)
Deprecated.CallsPlayer.getMediaItemAt(int)
on the delegate and returns the result.int
getMediaItemCount()
Deprecated.CallsPlayer.getMediaItemCount()
on the delegate and returns the result.MediaMetadata
getMediaMetadata()
Deprecated.CallsPlayer.getMediaMetadata()
on the delegate and returns the result.int
getNextMediaItemIndex()
Deprecated.CallsPlayer.getNextMediaItemIndex()
on the delegate and returns the result.int
getNextWindowIndex()
Deprecated.UsegetNextMediaItemIndex()
instead.PlaybackParameters
getPlaybackParameters()
Deprecated.CallsPlayer.getPlaybackParameters()
on the delegate and returns the result.int
getPlaybackState()
Deprecated.CallsPlayer.getPlaybackState()
on the delegate and returns the result.int
getPlaybackSuppressionReason()
Deprecated.CallsPlayer.getPlaybackSuppressionReason()
on the delegate and returns the result.PlaybackException
getPlayerError()
Deprecated.CallsPlayer.getPlayerError()
on the delegate and returns the result.MediaMetadata
getPlaylistMetadata()
Deprecated.CallsPlayer.getPlaylistMetadata()
on the delegate and returns the result.boolean
getPlayWhenReady()
Deprecated.CallsPlayer.getPlayWhenReady()
on the delegate and returns the result.int
getPreviousMediaItemIndex()
Deprecated.CallsPlayer.getPreviousMediaItemIndex()
on the delegate and returns the result.int
getPreviousWindowIndex()
Deprecated.UsegetPreviousMediaItemIndex()
instead.int
getRepeatMode()
Deprecated.CallsPlayer.getRepeatMode()
on the delegate and returns the result.long
getSeekBackIncrement()
Deprecated.CallsPlayer.getSeekBackIncrement()
on the delegate and returns the result.long
getSeekForwardIncrement()
Deprecated.CallsPlayer.getSeekForwardIncrement()
on the delegate and returns the result.boolean
getShuffleModeEnabled()
Deprecated.CallsPlayer.getShuffleModeEnabled()
on the delegate and returns the result.Size
getSurfaceSize()
Deprecated.CallsPlayer.getSurfaceSize()
on the delegate and returns the result.long
getTotalBufferedDuration()
Deprecated.CallsPlayer.getTotalBufferedDuration()
on the delegate and returns the result.TrackSelectionParameters
getTrackSelectionParameters()
Deprecated.CallsPlayer.getTrackSelectionParameters()
on the delegate and returns the result.VideoSize
getVideoSize()
Deprecated.CallsPlayer.getVideoSize()
on the delegate and returns the result.float
getVolume()
Deprecated.CallsPlayer.getVolume()
on the delegate and returns the result.Player
getWrappedPlayer()
Deprecated.Returns thePlayer
to which operations are forwarded.boolean
hasNext()
Deprecated.UsehasNextMediaItem()
instead.boolean
hasNextMediaItem()
Deprecated.CallsPlayer.hasNextMediaItem()
on the delegate and returns the result.boolean
hasNextWindow()
Deprecated.UsehasNextMediaItem()
instead.boolean
hasPrevious()
Deprecated.UsehasPreviousMediaItem()
instead.boolean
hasPreviousMediaItem()
Deprecated.CallsPlayer.hasPreviousMediaItem()
on the delegate and returns the result.boolean
hasPreviousWindow()
Deprecated.UsehasPreviousMediaItem()
instead.void
increaseDeviceVolume()
Deprecated.UseincreaseDeviceVolume(int)
instead.void
increaseDeviceVolume(@com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.increaseDeviceVolume(int)
on the delegate.boolean
isCommandAvailable(@com.google.android.exoplayer2.Player.Command int command)
Deprecated.CallsPlayer.isCommandAvailable(int)
on the delegate and returns the result.boolean
isCurrentMediaItemDynamic()
Deprecated.CallsPlayer.isCurrentMediaItemDynamic()
on the delegate and returns the result.boolean
isCurrentMediaItemLive()
Deprecated.CallsPlayer.isCurrentMediaItemLive()
on the delegate and returns the result.boolean
isCurrentMediaItemSeekable()
Deprecated.CallsPlayer.isCurrentMediaItemSeekable()
on the delegate and returns the result.boolean
isCurrentWindowDynamic()
Deprecated.UseisCurrentMediaItemDynamic()
instead.boolean
isCurrentWindowLive()
Deprecated.UseisCurrentMediaItemLive()
instead.boolean
isCurrentWindowSeekable()
Deprecated.UseisCurrentMediaItemSeekable()
instead.boolean
isDeviceMuted()
Deprecated.CallsPlayer.isDeviceMuted()
on the delegate and returns the result.boolean
isLoading()
Deprecated.CallsPlayer.isLoading()
on the delegate and returns the result.boolean
isPlaying()
Deprecated.CallsPlayer.isPlaying()
on the delegate and returns the result.boolean
isPlayingAd()
Deprecated.CallsPlayer.isPlayingAd()
on the delegate and returns the result.void
moveMediaItem(int currentIndex, int newIndex)
Deprecated.CallsPlayer.moveMediaItem(int, int)
on the delegate.void
moveMediaItems(int fromIndex, int toIndex, int newIndex)
Deprecated.CallsPlayer.moveMediaItems(int, int, int)
on the delegate.void
next()
Deprecated.UseseekToNextMediaItem()
instead.void
pause()
Deprecated.CallsPlayer.pause()
on the delegate.void
play()
Deprecated.CallsPlayer.play()
on the delegate.void
prepare()
Deprecated.CallsPlayer.prepare()
on the delegate.void
previous()
Deprecated.UseseekToPreviousMediaItem()
instead.void
release()
Deprecated.CallsPlayer.release()
on the delegate.void
removeListener(Player.Listener listener)
Deprecated.CallsPlayer.removeListener(Listener)
on the delegate.void
removeMediaItem(int index)
Deprecated.CallsPlayer.removeMediaItem(int)
on the delegate.void
removeMediaItems(int fromIndex, int toIndex)
Deprecated.CallsPlayer.removeMediaItems(int, int)
on the delegate.void
replaceMediaItem(int index, MediaItem mediaItem)
Deprecated.CallsPlayer.replaceMediaItem(int, MediaItem)
on the delegate.void
replaceMediaItems(int fromIndex, int toIndex, List<MediaItem> mediaItems)
Deprecated.CallsPlayer.replaceMediaItems(int, int, List)
on the delegate.void
seekBack()
Deprecated.CallsPlayer.seekBack()
on the delegate.void
seekForward()
Deprecated.CallsPlayer.seekForward()
on the delegate.void
seekTo(int mediaItemIndex, long positionMs)
Deprecated.CallsPlayer.seekTo(int, long)
on the delegate.void
seekTo(long positionMs)
Deprecated.CallsPlayer.seekTo(long)
on the delegate.void
seekToDefaultPosition()
Deprecated.CallsPlayer.seekToDefaultPosition()
on the delegate.void
seekToDefaultPosition(int mediaItemIndex)
Deprecated.CallsPlayer.seekToDefaultPosition(int)
on the delegate.void
seekToNext()
Deprecated.CallsPlayer.seekToNext()
on the delegate.void
seekToNextMediaItem()
Deprecated.CallsPlayer.seekToNextMediaItem()
on the delegate.void
seekToNextWindow()
Deprecated.UseseekToNextMediaItem()
instead.void
seekToPrevious()
Deprecated.CallsPlayer.seekToPrevious()
on the delegate.void
seekToPreviousMediaItem()
Deprecated.CallsPlayer.seekToPreviousMediaItem()
on the delegate.void
seekToPreviousWindow()
Deprecated.UseseekToPreviousMediaItem()
instead.void
setDeviceMuted(boolean muted)
Deprecated.UsesetDeviceMuted(boolean, int)
instead.void
setDeviceMuted(boolean muted, @com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.setDeviceMuted(boolean, int)
on the delegate.void
setDeviceVolume(int volume)
Deprecated.UsesetDeviceVolume(int, int)
instead.void
setDeviceVolume(int volume, @com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.setDeviceVolume(int, int)
on the delegate.void
setMediaItem(MediaItem mediaItem)
Deprecated.CallsPlayer.setMediaItem(MediaItem)
on the delegate.void
setMediaItem(MediaItem mediaItem, boolean resetPosition)
Deprecated.CallsPlayer.setMediaItem(MediaItem, boolean)
on the delegate.void
setMediaItem(MediaItem mediaItem, long startPositionMs)
Deprecated.CallsPlayer.setMediaItem(MediaItem, long)
on the delegate.void
setMediaItems(List<MediaItem> mediaItems)
Deprecated.CallsPlayer.setMediaItems(List)
on the delegate.void
setMediaItems(List<MediaItem> mediaItems, boolean resetPosition)
Deprecated.CallsPlayer.setMediaItems(List, boolean)
()} on the delegate.void
setMediaItems(List<MediaItem> mediaItems, int startIndex, long startPositionMs)
Deprecated.CallsPlayer.setMediaItems(List, int, long)
on the delegate.void
setPlaybackParameters(PlaybackParameters playbackParameters)
Deprecated.CallsPlayer.setPlaybackParameters(PlaybackParameters)
on the delegate.void
setPlaybackSpeed(float speed)
Deprecated.CallsPlayer.setPlaybackSpeed(float)
on the delegate.void
setPlaylistMetadata(MediaMetadata mediaMetadata)
Deprecated.CallsPlayer.setPlaylistMetadata(MediaMetadata)
on the delegate.void
setPlayWhenReady(boolean playWhenReady)
Deprecated.CallsPlayer.setPlayWhenReady(boolean)
on the delegate.void
setRepeatMode(@com.google.android.exoplayer2.Player.RepeatMode int repeatMode)
Deprecated.CallsPlayer.setRepeatMode(int)
on the delegate.void
setShuffleModeEnabled(boolean shuffleModeEnabled)
Deprecated.CallsPlayer.setShuffleModeEnabled(boolean)
on the delegate.void
setTrackSelectionParameters(TrackSelectionParameters parameters)
Deprecated.CallsPlayer.setTrackSelectionParameters(TrackSelectionParameters)
on the delegate.void
setVideoSurface(Surface surface)
Deprecated.CallsPlayer.setVideoSurface(Surface)
on the delegate.void
setVideoSurfaceHolder(SurfaceHolder surfaceHolder)
Deprecated.CallsPlayer.setVideoSurfaceHolder(SurfaceHolder)
on the delegate.void
setVideoSurfaceView(SurfaceView surfaceView)
Deprecated.CallsPlayer.setVideoSurfaceView(SurfaceView)
on the delegate.void
setVideoTextureView(TextureView textureView)
Deprecated.CallsPlayer.setVideoTextureView(TextureView)
on the delegate.void
setVolume(float volume)
Deprecated.CallsPlayer.setVolume(float)
on the delegate.void
stop()
Deprecated.CallsPlayer.stop()
on the delegate.
-
-
-
Constructor Detail
-
ForwardingPlayer
public ForwardingPlayer(Player player)
Deprecated.Creates a new instance that forwards all operations toplayer
.
-
-
Method Detail
-
getApplicationLooper
public Looper getApplicationLooper()
Deprecated.CallsPlayer.getApplicationLooper()
on the delegate and returns the result.- Specified by:
getApplicationLooper
in interfacePlayer
-
addListener
public void addListener(Player.Listener listener)
Deprecated.CallsPlayer.addListener(Listener)
on the delegate.Overrides of this method must not directly call
delegate.addListener
. If the override wants to pass thePlayer.Listener
instance to the delegatePlayer
, it must do so by callingsuper.addListener
instead. This ensures the correctPlayer
instance is passed toPlayer.Listener.onEvents(Player, Events)
(i.e. this forwarding instance, and not the underlyingdelegate
instance).- Specified by:
addListener
in interfacePlayer
- Parameters:
listener
- The listener to register.
-
removeListener
public void removeListener(Player.Listener listener)
Deprecated.CallsPlayer.removeListener(Listener)
on the delegate.Overrides of this method must not directly call
delegate.removeListener
. If the override wants to pass thePlayer.Listener
instance to the delegatePlayer
, it must do so by callingsuper.removeListener
instead.- Specified by:
removeListener
in interfacePlayer
- Parameters:
listener
- The listener to unregister.
-
setMediaItems
public void setMediaItems(List<MediaItem> mediaItems)
Deprecated.CallsPlayer.setMediaItems(List)
on the delegate.- Specified by:
setMediaItems
in interfacePlayer
- Parameters:
mediaItems
- The new media items.
-
setMediaItems
public void setMediaItems(List<MediaItem> mediaItems, boolean resetPosition)
Deprecated.CallsPlayer.setMediaItems(List, boolean)
()} on the delegate.- Specified by:
setMediaItems
in interfacePlayer
- Parameters:
mediaItems
- The new media items.resetPosition
- Whether the playback position should be reset to the default position in the firstTimeline.Window
. If false, playback will start from the position defined byPlayer.getCurrentMediaItemIndex()
andPlayer.getCurrentPosition()
.
-
setMediaItems
public void setMediaItems(List<MediaItem> mediaItems, int startIndex, long startPositionMs)
Deprecated.CallsPlayer.setMediaItems(List, int, long)
on the delegate.- Specified by:
setMediaItems
in interfacePlayer
- Parameters:
mediaItems
- The new media items.startIndex
- TheMediaItem
index to start playback from. IfC.INDEX_UNSET
is passed, the current position is not reset.startPositionMs
- The position in milliseconds to start playback from. IfC.TIME_UNSET
is passed, the default position of the givenMediaItem
is used. In any case, ifstartIndex
is set toC.INDEX_UNSET
, this parameter is ignored and the position is not reset at all.
-
setMediaItem
public void setMediaItem(MediaItem mediaItem)
Deprecated.CallsPlayer.setMediaItem(MediaItem)
on the delegate.- Specified by:
setMediaItem
in interfacePlayer
- Parameters:
mediaItem
- The newMediaItem
.
-
setMediaItem
public void setMediaItem(MediaItem mediaItem, long startPositionMs)
Deprecated.CallsPlayer.setMediaItem(MediaItem, long)
on the delegate.- Specified by:
setMediaItem
in interfacePlayer
- Parameters:
mediaItem
- The newMediaItem
.startPositionMs
- The position in milliseconds to start playback from.
-
setMediaItem
public void setMediaItem(MediaItem mediaItem, boolean resetPosition)
Deprecated.CallsPlayer.setMediaItem(MediaItem, boolean)
on the delegate.- Specified by:
setMediaItem
in interfacePlayer
- Parameters:
mediaItem
- The newMediaItem
.resetPosition
- Whether the playback position should be reset to the default position. If false, playback will start from the position defined byPlayer.getCurrentMediaItemIndex()
andPlayer.getCurrentPosition()
.
-
addMediaItem
public void addMediaItem(MediaItem mediaItem)
Deprecated.CallsPlayer.addMediaItem(MediaItem)
on the delegate.- Specified by:
addMediaItem
in interfacePlayer
- Parameters:
mediaItem
- TheMediaItem
to add.
-
addMediaItem
public void addMediaItem(int index, MediaItem mediaItem)
Deprecated.CallsPlayer.addMediaItem(int, MediaItem)
on the delegate.- Specified by:
addMediaItem
in interfacePlayer
- 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
- TheMediaItem
to add.
-
addMediaItems
public void addMediaItems(List<MediaItem> mediaItems)
Deprecated.CallsPlayer.addMediaItems(List)
on the delegate.- Specified by:
addMediaItems
in interfacePlayer
- Parameters:
mediaItems
- The media items to add.
-
addMediaItems
public void addMediaItems(int index, List<MediaItem> mediaItems)
Deprecated.CallsPlayer.addMediaItems(int, List)
on the delegate.- Specified by:
addMediaItems
in interfacePlayer
- 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 media items to add.
-
moveMediaItem
public void moveMediaItem(int currentIndex, int newIndex)
Deprecated.CallsPlayer.moveMediaItem(int, int)
on the delegate.- Specified by:
moveMediaItem
in interfacePlayer
- Parameters:
currentIndex
- The current index of the media item to move. If the index is larger than the size of the playlist, the request is ignored.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)
Deprecated.CallsPlayer.moveMediaItems(int, int, int)
on the delegate.- Specified by:
moveMediaItems
in interfacePlayer
- Parameters:
fromIndex
- The start of the range to move. If the index is larger than the size of the playlist, the request is ignored.toIndex
- The first item not to be included in the range (exclusive). If the index is larger than the size of the playlist, items up to the end of the playlist are moved.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.
-
replaceMediaItem
public void replaceMediaItem(int index, MediaItem mediaItem)
Deprecated.CallsPlayer.replaceMediaItem(int, MediaItem)
on the delegate.- Specified by:
replaceMediaItem
in interfacePlayer
- Parameters:
index
- The index at which to replace the media item. If the index is larger than the size of the playlist, the request is ignored.mediaItem
- The newMediaItem
.
-
replaceMediaItems
public void replaceMediaItems(int fromIndex, int toIndex, List<MediaItem> mediaItems)
Deprecated.CallsPlayer.replaceMediaItems(int, int, List)
on the delegate.- Specified by:
replaceMediaItems
in interfacePlayer
- Parameters:
fromIndex
- The start of the range. If the index is larger than the size of the playlist, the request is ignored.toIndex
- The first item not to be included in the range (exclusive). If the index is larger than the size of the playlist, items up to the end of the playlist are replaced.mediaItems
- The media items to replace the range with.
-
removeMediaItem
public void removeMediaItem(int index)
Deprecated.CallsPlayer.removeMediaItem(int)
on the delegate.- Specified by:
removeMediaItem
in interfacePlayer
- Parameters:
index
- The index at which to remove the media item. If the index is larger than the size of the playlist, the request is ignored.
-
removeMediaItems
public void removeMediaItems(int fromIndex, int toIndex)
Deprecated.CallsPlayer.removeMediaItems(int, int)
on the delegate.- Specified by:
removeMediaItems
in interfacePlayer
- Parameters:
fromIndex
- The index at which to start removing media items. If the index is larger than the size of the playlist, the request is ignored.toIndex
- The index of the first item to be kept (exclusive). If the index is larger than the size of the playlist, media items up to the end of the playlist are removed.
-
clearMediaItems
public void clearMediaItems()
Deprecated.CallsPlayer.clearMediaItems()
on the delegate.- Specified by:
clearMediaItems
in interfacePlayer
-
isCommandAvailable
public boolean isCommandAvailable(@Command @com.google.android.exoplayer2.Player.Command int command)
Deprecated.CallsPlayer.isCommandAvailable(int)
on the delegate and returns the result.- Specified by:
isCommandAvailable
in interfacePlayer
- Parameters:
command
- APlayer.Command
.- Returns:
- Whether the
Player.Command
is available. - See Also:
Player.Listener.onAvailableCommandsChanged(Commands)
-
canAdvertiseSession
public boolean canAdvertiseSession()
Deprecated.CallsPlayer.canAdvertiseSession()
on the delegate and returns the result.- Specified by:
canAdvertiseSession
in interfacePlayer
-
getAvailableCommands
public Player.Commands getAvailableCommands()
Deprecated.CallsPlayer.getAvailableCommands()
on the delegate and returns the result.- Specified by:
getAvailableCommands
in interfacePlayer
- Returns:
- The currently available
Player.Commands
. - See Also:
Player.Listener.onAvailableCommandsChanged(com.google.android.exoplayer2.Player.Commands)
-
prepare
public void prepare()
Deprecated.CallsPlayer.prepare()
on the delegate.
-
getPlaybackState
public int getPlaybackState()
Deprecated.CallsPlayer.getPlaybackState()
on the delegate and returns the result.- Specified by:
getPlaybackState
in interfacePlayer
- Returns:
- The current playback state.
- See Also:
Player.Listener.onPlaybackStateChanged(int)
-
getPlaybackSuppressionReason
public int getPlaybackSuppressionReason()
Deprecated.CallsPlayer.getPlaybackSuppressionReason()
on the delegate and returns the result.- Specified by:
getPlaybackSuppressionReason
in interfacePlayer
- Returns:
- The current
Player.PlaybackSuppressionReason
. - See Also:
Player.Listener.onPlaybackSuppressionReasonChanged(int)
-
isPlaying
public boolean isPlaying()
Deprecated.CallsPlayer.isPlaying()
on the delegate and returns the result.- Specified by:
isPlaying
in interfacePlayer
- Returns:
- Whether the player is playing.
- See Also:
Player.Listener.onIsPlayingChanged(boolean)
-
getPlayerError
@Nullable public PlaybackException getPlayerError()
Deprecated.CallsPlayer.getPlayerError()
on the delegate and returns the result.- Specified by:
getPlayerError
in interfacePlayer
- Returns:
- The error, or
null
. - See Also:
Player.Listener.onPlayerError(PlaybackException)
-
play
public void play()
Deprecated.CallsPlayer.play()
on the delegate.
-
pause
public void pause()
Deprecated.CallsPlayer.pause()
on the delegate.
-
setPlayWhenReady
public void setPlayWhenReady(boolean playWhenReady)
Deprecated.CallsPlayer.setPlayWhenReady(boolean)
on the delegate.- Specified by:
setPlayWhenReady
in interfacePlayer
- Parameters:
playWhenReady
- Whether playback should proceed when ready.
-
getPlayWhenReady
public boolean getPlayWhenReady()
Deprecated.CallsPlayer.getPlayWhenReady()
on the delegate and returns the result.- Specified by:
getPlayWhenReady
in interfacePlayer
- Returns:
- Whether playback will proceed when ready.
- See Also:
Player.Listener.onPlayWhenReadyChanged(boolean, int)
-
setRepeatMode
public void setRepeatMode(@RepeatMode @com.google.android.exoplayer2.Player.RepeatMode int repeatMode)
Deprecated.CallsPlayer.setRepeatMode(int)
on the delegate.- Specified by:
setRepeatMode
in interfacePlayer
- Parameters:
repeatMode
- The repeat mode.
-
getRepeatMode
public int getRepeatMode()
Deprecated.CallsPlayer.getRepeatMode()
on the delegate and returns the result.- Specified by:
getRepeatMode
in interfacePlayer
- Returns:
- The current repeat mode.
- See Also:
Player.Listener.onRepeatModeChanged(int)
-
setShuffleModeEnabled
public void setShuffleModeEnabled(boolean shuffleModeEnabled)
Deprecated.CallsPlayer.setShuffleModeEnabled(boolean)
on the delegate.- Specified by:
setShuffleModeEnabled
in interfacePlayer
- Parameters:
shuffleModeEnabled
- Whether shuffling is enabled.
-
getShuffleModeEnabled
public boolean getShuffleModeEnabled()
Deprecated.CallsPlayer.getShuffleModeEnabled()
on the delegate and returns the result.- Specified by:
getShuffleModeEnabled
in interfacePlayer
- See Also:
Player.Listener.onShuffleModeEnabledChanged(boolean)
-
isLoading
public boolean isLoading()
Deprecated.CallsPlayer.isLoading()
on the delegate and returns the result.- Specified by:
isLoading
in interfacePlayer
- Returns:
- Whether the player is currently loading the source.
- See Also:
Player.Listener.onIsLoadingChanged(boolean)
-
seekToDefaultPosition
public void seekToDefaultPosition()
Deprecated.CallsPlayer.seekToDefaultPosition()
on the delegate.- Specified by:
seekToDefaultPosition
in interfacePlayer
-
seekToDefaultPosition
public void seekToDefaultPosition(int mediaItemIndex)
Deprecated.CallsPlayer.seekToDefaultPosition(int)
on the delegate.- Specified by:
seekToDefaultPosition
in interfacePlayer
- Parameters:
mediaItemIndex
- The index of theMediaItem
whose associated default position should be seeked to. If the index is larger than the size of the playlist, the request is ignored.
-
seekTo
public void seekTo(long positionMs)
Deprecated.CallsPlayer.seekTo(long)
on the delegate.- Specified by:
seekTo
in interfacePlayer
- Parameters:
positionMs
- The seek position in the currentMediaItem
, orC.TIME_UNSET
to seek to the media item's default position.
-
seekTo
public void seekTo(int mediaItemIndex, long positionMs)
Deprecated.CallsPlayer.seekTo(int, long)
on the delegate.- Specified by:
seekTo
in interfacePlayer
- Parameters:
mediaItemIndex
- The index of theMediaItem
. If the index is larger than the size of the playlist, the request is ignored.positionMs
- The seek position in the specifiedMediaItem
, orC.TIME_UNSET
to seek to the media item's default position.
-
getSeekBackIncrement
public long getSeekBackIncrement()
Deprecated.CallsPlayer.getSeekBackIncrement()
on the delegate and returns the result.- Specified by:
getSeekBackIncrement
in interfacePlayer
- Returns:
- The seek back increment, in milliseconds.
- See Also:
Player.Listener.onSeekBackIncrementChanged(long)
-
seekBack
public void seekBack()
Deprecated.CallsPlayer.seekBack()
on the delegate.
-
getSeekForwardIncrement
public long getSeekForwardIncrement()
Deprecated.CallsPlayer.getSeekForwardIncrement()
on the delegate and returns the result.- Specified by:
getSeekForwardIncrement
in interfacePlayer
- Returns:
- The seek forward increment, in milliseconds.
- See Also:
Player.Listener.onSeekForwardIncrementChanged(long)
-
seekForward
public void seekForward()
Deprecated.CallsPlayer.seekForward()
on the delegate.- Specified by:
seekForward
in interfacePlayer
-
hasPrevious
@Deprecated public boolean hasPrevious()
Deprecated.UsehasPreviousMediaItem()
instead.CallsPlayer.hasPrevious()
on the delegate and returns the result.- Specified by:
hasPrevious
in interfacePlayer
-
hasPreviousWindow
@Deprecated public boolean hasPreviousWindow()
Deprecated.UsehasPreviousMediaItem()
instead.CallsPlayer.hasPreviousWindow()
on the delegate and returns the result.- Specified by:
hasPreviousWindow
in interfacePlayer
-
hasPreviousMediaItem
public boolean hasPreviousMediaItem()
Deprecated.CallsPlayer.hasPreviousMediaItem()
on the delegate and returns the result.- Specified by:
hasPreviousMediaItem
in interfacePlayer
-
previous
@Deprecated public void previous()
Deprecated.UseseekToPreviousMediaItem()
instead.CallsPlayer.previous()
on the delegate.
-
seekToPreviousWindow
@Deprecated public void seekToPreviousWindow()
Deprecated.UseseekToPreviousMediaItem()
instead.CallsPlayer.seekToPreviousWindow()
on the delegate.- Specified by:
seekToPreviousWindow
in interfacePlayer
-
seekToPreviousMediaItem
public void seekToPreviousMediaItem()
Deprecated.CallsPlayer.seekToPreviousMediaItem()
on the delegate.- Specified by:
seekToPreviousMediaItem
in interfacePlayer
-
seekToPrevious
public void seekToPrevious()
Deprecated.CallsPlayer.seekToPrevious()
on the delegate.- Specified by:
seekToPrevious
in interfacePlayer
-
getMaxSeekToPreviousPosition
public long getMaxSeekToPreviousPosition()
Deprecated.CallsPlayer.getMaxSeekToPreviousPosition()
on the delegate and returns the result.- Specified by:
getMaxSeekToPreviousPosition
in interfacePlayer
- Returns:
- The maximum seek to previous position, in milliseconds.
- See Also:
Player.Listener.onMaxSeekToPreviousPositionChanged(long)
-
hasNext
@Deprecated public boolean hasNext()
Deprecated.UsehasNextMediaItem()
instead.CallsPlayer.hasNext()
on the delegate and returns the result.
-
hasNextWindow
@Deprecated public boolean hasNextWindow()
Deprecated.UsehasNextMediaItem()
instead.CallsPlayer.hasNextWindow()
on the delegate and returns the result.- Specified by:
hasNextWindow
in interfacePlayer
-
hasNextMediaItem
public boolean hasNextMediaItem()
Deprecated.CallsPlayer.hasNextMediaItem()
on the delegate and returns the result.- Specified by:
hasNextMediaItem
in interfacePlayer
-
next
@Deprecated public void next()
Deprecated.UseseekToNextMediaItem()
instead.CallsPlayer.next()
on the delegate.
-
seekToNextWindow
@Deprecated public void seekToNextWindow()
Deprecated.UseseekToNextMediaItem()
instead.CallsPlayer.seekToNextWindow()
on the delegate.- Specified by:
seekToNextWindow
in interfacePlayer
-
seekToNextMediaItem
public void seekToNextMediaItem()
Deprecated.CallsPlayer.seekToNextMediaItem()
on the delegate.- Specified by:
seekToNextMediaItem
in interfacePlayer
-
seekToNext
public void seekToNext()
Deprecated.CallsPlayer.seekToNext()
on the delegate.- Specified by:
seekToNext
in interfacePlayer
-
setPlaybackParameters
public void setPlaybackParameters(PlaybackParameters playbackParameters)
Deprecated.CallsPlayer.setPlaybackParameters(PlaybackParameters)
on the delegate.- Specified by:
setPlaybackParameters
in interfacePlayer
- Parameters:
playbackParameters
- The playback parameters.
-
setPlaybackSpeed
public void setPlaybackSpeed(float speed)
Deprecated.CallsPlayer.setPlaybackSpeed(float)
on the delegate.- Specified by:
setPlaybackSpeed
in interfacePlayer
- 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()
Deprecated.CallsPlayer.getPlaybackParameters()
on the delegate and returns the result.- Specified by:
getPlaybackParameters
in interfacePlayer
- See Also:
Player.Listener.onPlaybackParametersChanged(PlaybackParameters)
-
stop
public void stop()
Deprecated.CallsPlayer.stop()
on the delegate.
-
release
public void release()
Deprecated.CallsPlayer.release()
on the delegate.
-
getCurrentTracks
public Tracks getCurrentTracks()
Deprecated.CallsPlayer.getCurrentTracks()
on the delegate and returns the result.- Specified by:
getCurrentTracks
in interfacePlayer
- See Also:
Player.Listener.onTracksChanged(Tracks)
-
getTrackSelectionParameters
public TrackSelectionParameters getTrackSelectionParameters()
Deprecated.CallsPlayer.getTrackSelectionParameters()
on the delegate and returns the result.- Specified by:
getTrackSelectionParameters
in interfacePlayer
- See Also:
}
-
setTrackSelectionParameters
public void setTrackSelectionParameters(TrackSelectionParameters parameters)
Deprecated.CallsPlayer.setTrackSelectionParameters(TrackSelectionParameters)
on the delegate.- Specified by:
setTrackSelectionParameters
in interfacePlayer
-
getMediaMetadata
public MediaMetadata getMediaMetadata()
Deprecated.CallsPlayer.getMediaMetadata()
on the delegate and returns the result.- Specified by:
getMediaMetadata
in interfacePlayer
-
getPlaylistMetadata
public MediaMetadata getPlaylistMetadata()
Deprecated.CallsPlayer.getPlaylistMetadata()
on the delegate and returns the result.- Specified by:
getPlaylistMetadata
in interfacePlayer
-
setPlaylistMetadata
public void setPlaylistMetadata(MediaMetadata mediaMetadata)
Deprecated.CallsPlayer.setPlaylistMetadata(MediaMetadata)
on the delegate.- Specified by:
setPlaylistMetadata
in interfacePlayer
-
getCurrentManifest
@Nullable public Object getCurrentManifest()
Deprecated.CallsPlayer.getCurrentManifest()
on the delegate and returns the result.- Specified by:
getCurrentManifest
in interfacePlayer
-
getCurrentTimeline
public Timeline getCurrentTimeline()
Deprecated.CallsPlayer.getCurrentTimeline()
on the delegate and returns the result.- Specified by:
getCurrentTimeline
in interfacePlayer
- See Also:
Player.Listener.onTimelineChanged(Timeline, int)
-
getCurrentPeriodIndex
public int getCurrentPeriodIndex()
Deprecated.CallsPlayer.getCurrentPeriodIndex()
on the delegate and returns the result.- Specified by:
getCurrentPeriodIndex
in interfacePlayer
-
getCurrentWindowIndex
@Deprecated public int getCurrentWindowIndex()
Deprecated.UsegetCurrentMediaItemIndex()
instead.CallsPlayer.getCurrentWindowIndex()
on the delegate and returns the result.- Specified by:
getCurrentWindowIndex
in interfacePlayer
-
getCurrentMediaItemIndex
public int getCurrentMediaItemIndex()
Deprecated.CallsPlayer.getCurrentMediaItemIndex()
on the delegate and returns the result.- Specified by:
getCurrentMediaItemIndex
in interfacePlayer
-
getNextWindowIndex
@Deprecated public int getNextWindowIndex()
Deprecated.UsegetNextMediaItemIndex()
instead.CallsPlayer.getNextWindowIndex()
on the delegate and returns the result.- Specified by:
getNextWindowIndex
in interfacePlayer
-
getNextMediaItemIndex
public int getNextMediaItemIndex()
Deprecated.CallsPlayer.getNextMediaItemIndex()
on the delegate and returns the result.- Specified by:
getNextMediaItemIndex
in interfacePlayer
-
getPreviousWindowIndex
@Deprecated public int getPreviousWindowIndex()
Deprecated.UsegetPreviousMediaItemIndex()
instead.CallsPlayer.getPreviousWindowIndex()
on the delegate and returns the result.- Specified by:
getPreviousWindowIndex
in interfacePlayer
-
getPreviousMediaItemIndex
public int getPreviousMediaItemIndex()
Deprecated.CallsPlayer.getPreviousMediaItemIndex()
on the delegate and returns the result.- Specified by:
getPreviousMediaItemIndex
in interfacePlayer
-
getCurrentMediaItem
@Nullable public MediaItem getCurrentMediaItem()
Deprecated.CallsPlayer.getCurrentMediaItem()
on the delegate and returns the result.- Specified by:
getCurrentMediaItem
in interfacePlayer
- See Also:
Player.Listener.onMediaItemTransition(MediaItem, int)
-
getMediaItemCount
public int getMediaItemCount()
Deprecated.CallsPlayer.getMediaItemCount()
on the delegate and returns the result.- Specified by:
getMediaItemCount
in interfacePlayer
-
getMediaItemAt
public MediaItem getMediaItemAt(int index)
Deprecated.CallsPlayer.getMediaItemAt(int)
on the delegate and returns the result.- Specified by:
getMediaItemAt
in interfacePlayer
-
getDuration
public long getDuration()
Deprecated.CallsPlayer.getDuration()
on the delegate and returns the result.- Specified by:
getDuration
in interfacePlayer
-
getCurrentPosition
public long getCurrentPosition()
Deprecated.CallsPlayer.getCurrentPosition()
on the delegate and returns the result.- Specified by:
getCurrentPosition
in interfacePlayer
-
getBufferedPosition
public long getBufferedPosition()
Deprecated.CallsPlayer.getBufferedPosition()
on the delegate and returns the result.- Specified by:
getBufferedPosition
in interfacePlayer
-
getBufferedPercentage
public int getBufferedPercentage()
Deprecated.CallsPlayer.getBufferedPercentage()
on the delegate and returns the result.- Specified by:
getBufferedPercentage
in interfacePlayer
-
getTotalBufferedDuration
public long getTotalBufferedDuration()
Deprecated.CallsPlayer.getTotalBufferedDuration()
on the delegate and returns the result.- Specified by:
getTotalBufferedDuration
in interfacePlayer
-
isCurrentWindowDynamic
@Deprecated public boolean isCurrentWindowDynamic()
Deprecated.UseisCurrentMediaItemDynamic()
instead.CallsPlayer.isCurrentWindowDynamic()
on the delegate and returns the result.- Specified by:
isCurrentWindowDynamic
in interfacePlayer
-
isCurrentMediaItemDynamic
public boolean isCurrentMediaItemDynamic()
Deprecated.CallsPlayer.isCurrentMediaItemDynamic()
on the delegate and returns the result.- Specified by:
isCurrentMediaItemDynamic
in interfacePlayer
- See Also:
Timeline.Window.isDynamic
-
isCurrentWindowLive
@Deprecated public boolean isCurrentWindowLive()
Deprecated.UseisCurrentMediaItemLive()
instead.CallsPlayer.isCurrentWindowLive()
on the delegate and returns the result.- Specified by:
isCurrentWindowLive
in interfacePlayer
-
isCurrentMediaItemLive
public boolean isCurrentMediaItemLive()
Deprecated.CallsPlayer.isCurrentMediaItemLive()
on the delegate and returns the result.- Specified by:
isCurrentMediaItemLive
in interfacePlayer
- See Also:
Timeline.Window.isLive()
-
getCurrentLiveOffset
public long getCurrentLiveOffset()
Deprecated.CallsPlayer.getCurrentLiveOffset()
on the delegate and returns the result.- Specified by:
getCurrentLiveOffset
in interfacePlayer
-
isCurrentWindowSeekable
@Deprecated public boolean isCurrentWindowSeekable()
Deprecated.UseisCurrentMediaItemSeekable()
instead.CallsPlayer.isCurrentWindowSeekable()
on the delegate and returns the result.- Specified by:
isCurrentWindowSeekable
in interfacePlayer
-
isCurrentMediaItemSeekable
public boolean isCurrentMediaItemSeekable()
Deprecated.CallsPlayer.isCurrentMediaItemSeekable()
on the delegate and returns the result.- Specified by:
isCurrentMediaItemSeekable
in interfacePlayer
- See Also:
Timeline.Window.isSeekable
-
isPlayingAd
public boolean isPlayingAd()
Deprecated.CallsPlayer.isPlayingAd()
on the delegate and returns the result.- Specified by:
isPlayingAd
in interfacePlayer
-
getCurrentAdGroupIndex
public int getCurrentAdGroupIndex()
Deprecated.CallsPlayer.getCurrentAdGroupIndex()
on the delegate and returns the result.- Specified by:
getCurrentAdGroupIndex
in interfacePlayer
-
getCurrentAdIndexInAdGroup
public int getCurrentAdIndexInAdGroup()
Deprecated.CallsPlayer.getCurrentAdIndexInAdGroup()
on the delegate and returns the result.- Specified by:
getCurrentAdIndexInAdGroup
in interfacePlayer
-
getContentDuration
public long getContentDuration()
Deprecated.CallsPlayer.getContentDuration()
on the delegate and returns the result.- Specified by:
getContentDuration
in interfacePlayer
-
getContentPosition
public long getContentPosition()
Deprecated.CallsPlayer.getContentPosition()
on the delegate and returns the result.- Specified by:
getContentPosition
in interfacePlayer
-
getContentBufferedPosition
public long getContentBufferedPosition()
Deprecated.CallsPlayer.getContentBufferedPosition()
on the delegate and returns the result.- Specified by:
getContentBufferedPosition
in interfacePlayer
-
getAudioAttributes
public AudioAttributes getAudioAttributes()
Deprecated.CallsPlayer.getAudioAttributes()
on the delegate and returns the result.- Specified by:
getAudioAttributes
in interfacePlayer
-
setVolume
public void setVolume(float volume)
Deprecated.CallsPlayer.setVolume(float)
on the delegate.
-
getVolume
public float getVolume()
Deprecated.CallsPlayer.getVolume()
on the delegate and returns the result.
-
getVideoSize
public VideoSize getVideoSize()
Deprecated.CallsPlayer.getVideoSize()
on the delegate and returns the result.- Specified by:
getVideoSize
in interfacePlayer
- See Also:
Player.Listener.onVideoSizeChanged(VideoSize)
-
getSurfaceSize
public Size getSurfaceSize()
Deprecated.CallsPlayer.getSurfaceSize()
on the delegate and returns the result.- Specified by:
getSurfaceSize
in interfacePlayer
- See Also:
Player.Listener.onSurfaceSizeChanged(int, int)
-
clearVideoSurface
public void clearVideoSurface()
Deprecated.CallsPlayer.clearVideoSurface()
on the delegate.- Specified by:
clearVideoSurface
in interfacePlayer
-
clearVideoSurface
public void clearVideoSurface(@Nullable Surface surface)
Deprecated.CallsPlayer.clearVideoSurface(Surface)
on the delegate.- Specified by:
clearVideoSurface
in interfacePlayer
- Parameters:
surface
- The surface to clear.
-
setVideoSurface
public void setVideoSurface(@Nullable Surface surface)
Deprecated.CallsPlayer.setVideoSurface(Surface)
on the delegate.- Specified by:
setVideoSurface
in interfacePlayer
- Parameters:
surface
- TheSurface
.
-
setVideoSurfaceHolder
public void setVideoSurfaceHolder(@Nullable SurfaceHolder surfaceHolder)
Deprecated.CallsPlayer.setVideoSurfaceHolder(SurfaceHolder)
on the delegate.- Specified by:
setVideoSurfaceHolder
in interfacePlayer
- Parameters:
surfaceHolder
- The surface holder.
-
clearVideoSurfaceHolder
public void clearVideoSurfaceHolder(@Nullable SurfaceHolder surfaceHolder)
Deprecated.CallsPlayer.clearVideoSurfaceHolder(SurfaceHolder)
on the delegate.- Specified by:
clearVideoSurfaceHolder
in interfacePlayer
- Parameters:
surfaceHolder
- The surface holder to clear.
-
setVideoSurfaceView
public void setVideoSurfaceView(@Nullable SurfaceView surfaceView)
Deprecated.CallsPlayer.setVideoSurfaceView(SurfaceView)
on the delegate.- Specified by:
setVideoSurfaceView
in interfacePlayer
- Parameters:
surfaceView
- The surface view.
-
clearVideoSurfaceView
public void clearVideoSurfaceView(@Nullable SurfaceView surfaceView)
Deprecated.CallsPlayer.clearVideoSurfaceView(SurfaceView)
on the delegate.- Specified by:
clearVideoSurfaceView
in interfacePlayer
- Parameters:
surfaceView
- The texture view to clear.
-
setVideoTextureView
public void setVideoTextureView(@Nullable TextureView textureView)
Deprecated.CallsPlayer.setVideoTextureView(TextureView)
on the delegate.- Specified by:
setVideoTextureView
in interfacePlayer
- Parameters:
textureView
- The texture view.
-
clearVideoTextureView
public void clearVideoTextureView(@Nullable TextureView textureView)
Deprecated.CallsPlayer.clearVideoTextureView(TextureView)
on the delegate.- Specified by:
clearVideoTextureView
in interfacePlayer
- Parameters:
textureView
- The texture view to clear.
-
getCurrentCues
public CueGroup getCurrentCues()
Deprecated.CallsPlayer.getCurrentCues()
on the delegate and returns the result.- Specified by:
getCurrentCues
in interfacePlayer
-
getDeviceInfo
public DeviceInfo getDeviceInfo()
Deprecated.CallsPlayer.getDeviceInfo()
on the delegate and returns the result.- Specified by:
getDeviceInfo
in interfacePlayer
-
getDeviceVolume
public int getDeviceVolume()
Deprecated.CallsPlayer.getDeviceVolume()
on the delegate and returns the result.- Specified by:
getDeviceVolume
in interfacePlayer
-
isDeviceMuted
public boolean isDeviceMuted()
Deprecated.CallsPlayer.isDeviceMuted()
on the delegate and returns the result.- Specified by:
isDeviceMuted
in interfacePlayer
-
setDeviceVolume
@Deprecated public void setDeviceVolume(int volume)
Deprecated.UsesetDeviceVolume(int, int)
instead.- Specified by:
setDeviceVolume
in interfacePlayer
-
setDeviceVolume
public void setDeviceVolume(int volume, @com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.setDeviceVolume(int, int)
on the delegate.- Specified by:
setDeviceVolume
in interfacePlayer
- Parameters:
volume
- The volume to set.flags
- Either 0 or a bitwise combination of one or moreC.VolumeFlags
.
-
increaseDeviceVolume
@Deprecated public void increaseDeviceVolume()
Deprecated.UseincreaseDeviceVolume(int)
instead.- Specified by:
increaseDeviceVolume
in interfacePlayer
-
increaseDeviceVolume
public void increaseDeviceVolume(@com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.increaseDeviceVolume(int)
on the delegate.- Specified by:
increaseDeviceVolume
in interfacePlayer
- Parameters:
flags
- Either 0 or a bitwise combination of one or moreC.VolumeFlags
.
-
decreaseDeviceVolume
@Deprecated public void decreaseDeviceVolume()
Deprecated.UsedecreaseDeviceVolume(int)
instead.- Specified by:
decreaseDeviceVolume
in interfacePlayer
-
decreaseDeviceVolume
public void decreaseDeviceVolume(@com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.decreaseDeviceVolume(int)
on the delegate.- Specified by:
decreaseDeviceVolume
in interfacePlayer
- Parameters:
flags
- Either 0 or a bitwise combination of one or moreC.VolumeFlags
.
-
setDeviceMuted
@Deprecated public void setDeviceMuted(boolean muted)
Deprecated.UsesetDeviceMuted(boolean, int)
instead.- Specified by:
setDeviceMuted
in interfacePlayer
-
setDeviceMuted
public void setDeviceMuted(boolean muted, @com.google.android.exoplayer2.C.VolumeFlags int flags)
Deprecated.CallsPlayer.setDeviceMuted(boolean, int)
on the delegate.- Specified by:
setDeviceMuted
in interfacePlayer
- Parameters:
muted
- Whether to set the device to be muted or notflags
- Either 0 or a bitwise combination of one or moreC.VolumeFlags
.
-
-