Session

class Session(val periodUid: Any, val window: Timeline.Window)

Represents a playback session associated with a MediaItem in a Timeline.

  • A session is linked to the period inside the timeline, see Timeline.getUidOfPeriod.

  • A session is created when the player interacts with a MediaItem.

  • A session is considered the "current" session if its mediaItem is the current MediaItem.

  • A session is destroyed when:

    • It's no longer the current session (e.g., switching media items).

    • Its mediaItem is removed from the playlist.

    • The player is released.

Constructors

Link copied to clipboard
constructor(periodUid: Any, window: Timeline.Window)

Properties

Link copied to clipboard

The MediaItem associated with this session.

Link copied to clipboard

The id of the period in the timeline, obtained from Timeline.getUidOfPeriod.

Link copied to clipboard

Unique identifier for this session.

Link copied to clipboard

The last known Window associated with this session.

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open override fun toString(): String