# Print output for @column tags ?>
public
static
final
class
AudioPresentation.Builder
extends Object
| java.lang.Object | |
| ↳ | android.media.AudioPresentation.Builder |
A builder class for creating AudioPresentation objects.
Public constructors | |
|---|---|
Builder(int presentationId)
Create a |
|
Public methods | |
|---|---|
AudioPresentation
|
build()
Creates a |
AudioPresentation.Builder
|
setHasAudioDescription(boolean audioDescriptionAvailable)
Indicate whether the presentation contains audio description for the visually impaired. |
AudioPresentation.Builder
|
setHasDialogueEnhancement(boolean dialogueEnhancementAvailable)
Indicate whether the presentation supports dialogue enhancement. |
AudioPresentation.Builder
|
setHasSpokenSubtitles(boolean spokenSubtitlesAvailable)
Indicate whether the presentation contains spoken subtitles for the visually impaired. |
AudioPresentation.Builder
|
setLabels(Map<ULocale, CharSequence> labels)
Sets locale / text label pairs describing the presentation. |
AudioPresentation.Builder
|
setLocale(ULocale language)
Sets the language information of the audio presentation. |
AudioPresentation.Builder
|
setMasteringIndication(int masteringIndication)
Sets the mastering indication. |
AudioPresentation.Builder
|
setProgramId(int programId)
Sets the ProgramId to which this audio presentation refers. |
Inherited methods | |
|---|---|
public Builder (int presentationId)
Create a Builder. Any field that should be included in the
AudioPresentation must be added.
| Parameters | |
|---|---|
presentationId |
int: The presentation ID of this audio presentation. |
public AudioPresentation build ()
Creates a AudioPresentation instance with the specified fields.
| Returns | |
|---|---|
AudioPresentation |
The new AudioPresentation instance
This value cannot be null. |
public AudioPresentation.Builder setHasAudioDescription (boolean audioDescriptionAvailable)
Indicate whether the presentation contains audio description for the visually impaired.
| Parameters | |
|---|---|
audioDescriptionAvailable |
boolean: Audio description for the visually impaired. |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |
public AudioPresentation.Builder setHasDialogueEnhancement (boolean dialogueEnhancementAvailable)
Indicate whether the presentation supports dialogue enhancement.
| Parameters | |
|---|---|
dialogueEnhancementAvailable |
boolean: Dialogue enhancement. |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |
public AudioPresentation.Builder setHasSpokenSubtitles (boolean spokenSubtitlesAvailable)
Indicate whether the presentation contains spoken subtitles for the visually impaired.
| Parameters | |
|---|---|
spokenSubtitlesAvailable |
boolean: Spoken subtitles for the visually impaired. |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |
public AudioPresentation.Builder setLabels (Map<ULocale, CharSequence> labels)
Sets locale / text label pairs describing the presentation.
| Parameters | |
|---|---|
labels |
Map: Text label indexed by its locale corresponding to the language code.
This value cannot be null. |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |
public AudioPresentation.Builder setLocale (ULocale language)
Sets the language information of the audio presentation.
| Parameters | |
|---|---|
language |
ULocale: Locale corresponding to ISO 639-1/639-2 language code.
This value cannot be null. |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |
public AudioPresentation.Builder setMasteringIndication (int masteringIndication)
Sets the mastering indication.
| Parameters | |
|---|---|
masteringIndication |
int: Input to set mastering indication.
Value is AudioPresentation.MASTERING_NOT_INDICATED, AudioPresentation.MASTERED_FOR_STEREO, AudioPresentation.MASTERED_FOR_SURROUND, AudioPresentation.MASTERED_FOR_3D, or AudioPresentation.MASTERED_FOR_HEADPHONE |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |
| Throws | |
|---|---|
IllegalArgumentException |
if the mastering indication is not any of
AudioPresentation#MASTERING_NOT_INDICATED,
AudioPresentation#MASTERED_FOR_STEREO,
AudioPresentation#MASTERED_FOR_SURROUND,
AudioPresentation#MASTERED_FOR_3D,
and AudioPresentation#MASTERED_FOR_HEADPHONE |
public AudioPresentation.Builder setProgramId (int programId)
Sets the ProgramId to which this audio presentation refers.
| Parameters | |
|---|---|
programId |
int: The program ID to be decoded. |
| Returns | |
|---|---|
AudioPresentation.Builder |
This value cannot be null. |