MediaItem.SubtitleConfiguration.Builder


class MediaItem.SubtitleConfiguration.Builder


Builder for SubtitleConfiguration instances.

Summary

Public constructors

Builder(uri: Uri!)

Constructs an instance.

Public functions

MediaItem.SubtitleConfiguration!

Creates a SubtitleConfiguration from the values of this builder.

MediaItem.SubtitleConfiguration.Builder!

Sets the optional ID for this subtitle track.

MediaItem.SubtitleConfiguration.Builder!

Sets the optional label for this subtitle track.

MediaItem.SubtitleConfiguration.Builder!

Sets the optional language of the subtitle file.

MediaItem.SubtitleConfiguration.Builder!

Sets the MIME type.

MediaItem.SubtitleConfiguration.Builder!

Sets the role flags.

MediaItem.SubtitleConfiguration.Builder!

Sets the flags used for track selection.

MediaItem.SubtitleConfiguration.Builder!

Sets the Uri to the subtitle file.

Public constructors

Builder

Builder(uri: Uri!)

Constructs an instance.

Parameters
uri: Uri!

The Uri to the subtitle file.

Public functions

build

fun build(): MediaItem.SubtitleConfiguration!

Creates a SubtitleConfiguration from the values of this builder.

setId

@CanIgnoreReturnValue
fun setId(id: String?): MediaItem.SubtitleConfiguration.Builder!

Sets the optional ID for this subtitle track.

setLabel

@CanIgnoreReturnValue
fun setLabel(label: String?): MediaItem.SubtitleConfiguration.Builder!

Sets the optional label for this subtitle track.

setLanguage

@CanIgnoreReturnValue
fun setLanguage(language: String?): MediaItem.SubtitleConfiguration.Builder!

Sets the optional language of the subtitle file.

setMimeType

@CanIgnoreReturnValue
fun setMimeType(mimeType: String?): MediaItem.SubtitleConfiguration.Builder!

Sets the MIME type.

setRoleFlags

@CanIgnoreReturnValue
fun setRoleFlags(@C.RoleFlags roleFlags: Int): MediaItem.SubtitleConfiguration.Builder!

Sets the role flags. These are used for track selection.

setSelectionFlags

@CanIgnoreReturnValue
fun setSelectionFlags(@C.SelectionFlags selectionFlags: Int): MediaItem.SubtitleConfiguration.Builder!

Sets the flags used for track selection.

setUri

@CanIgnoreReturnValue
fun setUri(uri: Uri!): MediaItem.SubtitleConfiguration.Builder!

Sets the Uri to the subtitle file.