MediaSession.MediaItemsWithStartPosition


@UnstableApi
class MediaSession.MediaItemsWithStartPosition


Representation of a list of media items and where to start playing.

Summary

Public constructors

MediaItemsWithStartPosition(
    mediaItems: (Mutable)List<MediaItem!>!,
    startIndex: Int,
    startPositionMs: Long
)

Creates an instance.

Public functions

Boolean
equals(obj: Any?)
Int

Public properties

ImmutableList<MediaItem!>!

List of media items.

Int

Index to start playing at in mediaItems.

Long

Position in milliseconds to start playing from in the starting media item.

Public constructors

MediaItemsWithStartPosition

MediaItemsWithStartPosition(
    mediaItems: (Mutable)List<MediaItem!>!,
    startIndex: Int,
    startPositionMs: Long
)

Creates an instance.

Parameters
mediaItems: (Mutable)List<MediaItem!>!

List of media items.

startIndex: Int

Index to start playing at in mediaItems, or INDEX_UNSET to start from the default index.

startPositionMs: Long

Position in milliseconds to start playing from in the starting media item, or TIME_UNSET to start from the default position.

Public functions

equals

fun equals(obj: Any?): Boolean

hashCode

fun hashCode(): Int

Public properties

mediaItems

val mediaItems: ImmutableList<MediaItem!>!

List of media items.

startIndex

val startIndex: Int

Index to start playing at in mediaItems.

The start index in mediaItems from which to start playing, or INDEX_UNSET to start playing from the default index in the playlist.

startPositionMs

val startPositionMs: Long

Position in milliseconds to start playing from in the starting media item.

The starting position in the media item from where to start playing, or TIME_UNSET to start playing from the default position in the media item. This value is ignored if startIndex is INDEX_UNSET.