Package com.google.android.exoplayer2
Class Player.PositionInfo
- java.lang.Object
-
- com.google.android.exoplayer2.Player.PositionInfo
-
- All Implemented Interfaces:
Bundleable
- Enclosing interface:
- Player
public static final class Player.PositionInfo extends Object implements Bundleable
Position info describing a playback position involved in a discontinuity.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.google.android.exoplayer2.Bundleable
Bundleable.Creator<T extends Bundleable>
-
-
Field Summary
Fields Modifier and Type Field Description int
adGroupIndex
The ad group index if the playback position is within an ad,C.INDEX_UNSET
otherwise.int
adIndexInAdGroup
The index of the ad within the ad group if the playback position is within an ad,C.INDEX_UNSET
otherwise.long
contentPositionMs
The content position, in milliseconds.static Bundleable.Creator<Player.PositionInfo>
CREATOR
Object that can restorePlayer.PositionInfo
from aBundle
.int
periodIndex
The period index.Object
periodUid
The UID of the period, ornull
, if the timeline isempty
.long
positionMs
The playback position, in milliseconds.int
windowIndex
The window index.Object
windowUid
The UID of the window, ornull
, if the timeline isempty
.
-
Constructor Summary
Constructors Constructor Description PositionInfo(Object windowUid, int windowIndex, Object periodUid, int periodIndex, long positionMs, long contentPositionMs, int adGroupIndex, int adIndexInAdGroup)
Creates an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
int
hashCode()
Bundle
toBundle()
Returns aBundle
representing the information stored in this object.
-
-
-
Field Detail
-
windowUid
@Nullable public final Object windowUid
The UID of the window, ornull
, if the timeline isempty
.
-
windowIndex
public final int windowIndex
The window index.
-
periodUid
@Nullable public final Object periodUid
The UID of the period, ornull
, if the timeline isempty
.
-
periodIndex
public final int periodIndex
The period index.
-
positionMs
public final long positionMs
The playback position, in milliseconds.
-
contentPositionMs
public final long contentPositionMs
The content position, in milliseconds.If
adGroupIndex
isC.INDEX_UNSET
, this is the same aspositionMs
.
-
adGroupIndex
public final int adGroupIndex
The ad group index if the playback position is within an ad,C.INDEX_UNSET
otherwise.
-
adIndexInAdGroup
public final int adIndexInAdGroup
The index of the ad within the ad group if the playback position is within an ad,C.INDEX_UNSET
otherwise.
-
CREATOR
public static final Bundleable.Creator<Player.PositionInfo> CREATOR
Object that can restorePlayer.PositionInfo
from aBundle
.
-
-