Period
@UnstableApi
public class Period
Encapsulates media content components over a contiguous period of time.
Summary
Public fields |
|
|---|---|
final List<AdaptationSet> |
The adaptation sets belonging to the period. |
final @Nullable Descriptor |
The asset identifier for this period, if one exists |
final List<EventStream> |
The event stream belonging to the period. |
final @Nullable String |
The period identifier, if one exists. |
final long |
The start time of the period in milliseconds, relative to the start of the manifest. |
Public constructors |
|---|
Period( |
Period( |
Period( |
Public methods |
|
|---|---|
int |
getAdaptationSetIndex(int type)Returns the index of the first adaptation set of a given type, or |
Public fields
adaptationSets
public final List<AdaptationSet> adaptationSets
The adaptation sets belonging to the period.
assetIdentifier
public final @Nullable Descriptor assetIdentifier
The asset identifier for this period, if one exists
startMs
public final long startMs
The start time of the period in milliseconds, relative to the start of the manifest.
Public constructors
Period
public Period(
@Nullable String id,
long startMs,
List<AdaptationSet> adaptationSets
)
| Parameters | |
|---|---|
@Nullable String id |
The period identifier. May be null. |
long startMs |
The start time of the period in milliseconds. |
List<AdaptationSet> adaptationSets |
The adaptation sets belonging to the period. |
Period
public Period(
@Nullable String id,
long startMs,
List<AdaptationSet> adaptationSets,
List<EventStream> eventStreams
)
| Parameters | |
|---|---|
@Nullable String id |
The period identifier. May be null. |
long startMs |
The start time of the period in milliseconds. |
List<AdaptationSet> adaptationSets |
The adaptation sets belonging to the period. |
List<EventStream> eventStreams |
The |
Period
public Period(
@Nullable String id,
long startMs,
List<AdaptationSet> adaptationSets,
List<EventStream> eventStreams,
@Nullable Descriptor assetIdentifier
)
| Parameters | |
|---|---|
@Nullable String id |
The period identifier. May be null. |
long startMs |
The start time of the period in milliseconds. |
List<AdaptationSet> adaptationSets |
The adaptation sets belonging to the period. |
List<EventStream> eventStreams |
The |
@Nullable Descriptor assetIdentifier |
The asset identifier for this period |
Public methods
getAdaptationSetIndex
public int getAdaptationSetIndex(int type)
Returns the index of the first adaptation set of a given type, or INDEX_UNSET if no adaptation set of the specified type exists.
| Parameters | |
|---|---|
int type |
An adaptation set type. |
| Returns | |
|---|---|
int |
The index of the first adaptation set of the specified type, or |