docs/doc/reference/com/google/android/exoplayer2/SimpleBasePlayer.PeriodData.Builder.html
Package com.google.android.exoplayer2
Enclosing class:SimpleBasePlayer.PeriodData
public static final classSimpleBasePlayer.PeriodData.Builderextends[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")
A builder for SimpleBasePlayer.PeriodData objects.
Constructors | Constructor | Description |
| --- | --- |
| Builder(Object uid) |
Creates the builder.
|
All Methods Instance Methods Concrete Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| SimpleBasePlayer.PeriodData | build() |
Builds the SimpleBasePlayer.PeriodData.
|
| SimpleBasePlayer.PeriodData.Builder | setAdPlaybackState(AdPlaybackState adPlaybackState) |
Sets the AdPlaybackState.
|
| SimpleBasePlayer.PeriodData.Builder | setDurationUs(long durationUs) |
Sets the total duration of the period, in microseconds, or C.TIME_UNSET if unknown.
|
| SimpleBasePlayer.PeriodData.Builder | setIsPlaceholder(boolean isPlaceholder) |
Sets whether this period contains placeholder information because the real information has yet to be loaded
|
| SimpleBasePlayer.PeriodData.Builder | setUid(Object uid) |
Sets the unique identifier of the period within its media item.
|
-
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
public Builder([Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")uid)
Creates the builder.
Parameters:uid - The unique identifier of the period within its media item.
-
@CanIgnoreReturnValue
public[SimpleBasePlayer.PeriodData.Builder](SimpleBasePlayer.PeriodData.Builder.html "class in com.google.android.exoplayer2")setUid([Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")uid)
Sets the unique identifier of the period within its media item.
Parameters:uid - The unique identifier of the period within its media item.Returns:This builder.
-
@CanIgnoreReturnValue
public[SimpleBasePlayer.PeriodData.Builder](SimpleBasePlayer.PeriodData.Builder.html "class in com.google.android.exoplayer2")setDurationUs(long durationUs)
Sets the total duration of the period, in microseconds, or C.TIME_UNSET if unknown.
Only the last period in a media item can have an unknown duration.
Parameters:durationUs - The total duration of the period, in microseconds, or C.TIME_UNSET if unknown.Returns:This builder.
-
@CanIgnoreReturnValue
public[SimpleBasePlayer.PeriodData.Builder](SimpleBasePlayer.PeriodData.Builder.html "class in com.google.android.exoplayer2")setAdPlaybackState([AdPlaybackState](source/ads/AdPlaybackState.html "class in com.google.android.exoplayer2.source.ads")adPlaybackState)
Sets the AdPlaybackState.
Parameters:adPlaybackState - The AdPlaybackState, or AdPlaybackState.NONE if there are no ads.Returns:This builder.
-
@CanIgnoreReturnValue
public[SimpleBasePlayer.PeriodData.Builder](SimpleBasePlayer.PeriodData.Builder.html "class in com.google.android.exoplayer2")setIsPlaceholder(boolean isPlaceholder)
Sets whether this period contains placeholder information because the real information has yet to be loaded
Parameters:isPlaceholder - Whether this period contains placeholder information because the real information has yet to be loaded.Returns:This builder.
-
public[SimpleBasePlayer.PeriodData](SimpleBasePlayer.PeriodData.html "class in com.google.android.exoplayer2")build()
Builds the SimpleBasePlayer.PeriodData.