DefaultPreloadManager.PreloadStatus


class DefaultPreloadManager.PreloadStatus


Defines the preload status for the DefaultPreloadManager.

Summary

Nested types

@Documented
@Retention(value = RetentionPolicy.SOURCE)
@Target(value = TYPE_USE)
@IntDef(value = )
annotation DefaultPreloadManager.PreloadStatus.Stage

Stages for the preload status.

Constants

const DefaultPreloadManager.PreloadStatus!

A PreloadStatus indicating that the source has completed preparation.

const Int

The PreloadMediaSource has completed preparation.

const Int

The PreloadMediaSource has been loaded for a specific range defined by startPositionMs and durationMs.

const Int

The PreloadMediaSource has tracks selected.

const DefaultPreloadManager.PreloadStatus!

A PreloadStatus indicating that the source has tracks selected.

Public functions

java-static DefaultPreloadManager.PreloadStatus!

Returns a PreloadStatus indicating to load the source from the default start position and for the specified duration.

java-static DefaultPreloadManager.PreloadStatus!
specifiedRangeLoaded(startPositionMs: Long, durationMs: Long)

Returns a PreloadStatus indicating to load the source from the specified start position and for the specified duration.

Public properties

Long

The duration in milliseconds for which the source should be loaded from the startPositionMs, or TIME_UNSET to indicate that the source should be loaded to end of source.

Int

The stage for the preload status.

Long

The start position in milliseconds from which the source should be loaded, or TIME_UNSET to indicate the default start position.

Constants

SOURCE_PREPARED

const val SOURCE_PREPAREDDefaultPreloadManager.PreloadStatus!

A PreloadStatus indicating that the source has completed preparation.

STAGE_SOURCE_PREPARED

const val STAGE_SOURCE_PREPARED = 0: Int

The PreloadMediaSource has completed preparation.

STAGE_SPECIFIED_RANGE_LOADED

const val STAGE_SPECIFIED_RANGE_LOADED = 2: Int

The PreloadMediaSource has been loaded for a specific range defined by startPositionMs and durationMs.

STAGE_TRACKS_SELECTED

const val STAGE_TRACKS_SELECTED = 1: Int

The PreloadMediaSource has tracks selected.

TRACKS_SELECTED

const val TRACKS_SELECTEDDefaultPreloadManager.PreloadStatus!

A PreloadStatus indicating that the source has tracks selected.

Public functions

specifiedRangeLoaded

java-static fun specifiedRangeLoaded(durationMs: Long): DefaultPreloadManager.PreloadStatus!

Returns a PreloadStatus indicating to load the source from the default start position and for the specified duration.

specifiedRangeLoaded

java-static fun specifiedRangeLoaded(startPositionMs: Long, durationMs: Long): DefaultPreloadManager.PreloadStatus!

Returns a PreloadStatus indicating to load the source from the specified start position and for the specified duration.

Public properties

durationMs

val durationMsLong

The duration in milliseconds for which the source should be loaded from the startPositionMs, or TIME_UNSET to indicate that the source should be loaded to end of source.

stage

@DefaultPreloadManager.PreloadStatus.Stage
val stageInt

The stage for the preload status.

startPositionMs

val startPositionMsLong

The start position in milliseconds from which the source should be loaded, or TIME_UNSET to indicate the default start position.