MediaItem.LiveConfiguration.Builder
public final class MediaItem.LiveConfiguration.Builder
Builder for LiveConfiguration instances.
Summary
Public constructors |
|---|
Builder()Creates a new instance with default values. |
Public methods |
|
|---|---|
MediaItem.LiveConfiguration |
build()Creates a |
MediaItem.LiveConfiguration.Builder |
@CanIgnoreReturnValueSets the maximum allowed live offset, in milliseconds. |
MediaItem.LiveConfiguration.Builder |
@CanIgnoreReturnValueSets the maximum playback speed. |
MediaItem.LiveConfiguration.Builder |
@CanIgnoreReturnValueSets the minimum allowed live offset, in milliseconds. |
MediaItem.LiveConfiguration.Builder |
@CanIgnoreReturnValueSets the minimum playback speed. |
MediaItem.LiveConfiguration.Builder |
@CanIgnoreReturnValueSets the target live offset, in milliseconds. |
Public constructors
Public methods
build
public MediaItem.LiveConfiguration build()
Creates a LiveConfiguration with the values from this builder.
setMaxOffsetMs
@CanIgnoreReturnValue
public MediaItem.LiveConfiguration.Builder setMaxOffsetMs(long maxOffsetMs)
Sets the maximum allowed live offset, in milliseconds.
See Player#getCurrentLiveOffset().
Defaults to TIME_UNSET, indicating the media-defined default will be used.
setMaxPlaybackSpeed
@CanIgnoreReturnValue
public MediaItem.LiveConfiguration.Builder setMaxPlaybackSpeed(float maxPlaybackSpeed)
Sets the maximum playback speed.
Defaults to RATE_UNSET, indicating the media-defined default will be used.
setMinOffsetMs
@CanIgnoreReturnValue
public MediaItem.LiveConfiguration.Builder setMinOffsetMs(long minOffsetMs)
Sets the minimum allowed live offset, in milliseconds.
See Player#getCurrentLiveOffset().
Defaults to TIME_UNSET, indicating the media-defined default will be used.
setMinPlaybackSpeed
@CanIgnoreReturnValue
public MediaItem.LiveConfiguration.Builder setMinPlaybackSpeed(float minPlaybackSpeed)
Sets the minimum playback speed.
Defaults to RATE_UNSET, indicating the media-defined default will be used.
setTargetOffsetMs
@CanIgnoreReturnValue
public MediaItem.LiveConfiguration.Builder setTargetOffsetMs(long targetOffsetMs)
Sets the target live offset, in milliseconds.
See Player#getCurrentLiveOffset().
Defaults to TIME_UNSET, indicating the media-defined default will be used.