Back to Exoplayer

FakeAdaptiveDataSet (ExoPlayer library)

docs/doc/reference/com/google/android/exoplayer2/testutil/FakeAdaptiveDataSet.html

latest2.9 KB
Original Source

Package com.google.android.exoplayer2.testutil

Class FakeAdaptiveDataSet


public final classFakeAdaptiveDataSetextends[FakeDataSet](FakeDataSet.html "class in com.google.android.exoplayer2.testutil")

Fake data set emulating the data of an adaptive media source. It provides chunk data for all Formats in the given TrackGroup.

Nested Class Summary

Nested Classes | Modifier and Type | Class | Description | | --- | --- | --- | | static class | FakeAdaptiveDataSet.Factory | Factory for FakeAdaptiveDataSets. | | static class | FakeAdaptiveDataSet.Iterator | MediaChunkIterator for the chunks defined by a fake adaptive data set. |

- 

Nested classes/interfaces inherited from class com.google.android.exoplayer2.testutil.FakeDataSet

FakeDataSet.FakeData

Method Summary

All Methods Instance Methods Concrete Methods | Modifier and Type | Method | Description | | --- | --- | --- | | int | getChunkCount() | | | long | getChunkDuration​(int chunkIndex) | | | int | getChunkIndexByPosition​(long positionUs) | | | long | getStartTime​(int chunkIndex) | | | String | getUri​(int trackIndex) | |

- 

Methods inherited from class com.google.android.exoplayer2.testutil.FakeDataSet

getAllData, getData, getData, newData, newData, newDefaultData, setData, setData, setRandomData, setRandomData

- 

Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Method Detail

- 

getChunkCount

public int getChunkCount()
- 

getUri

public[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")getUri​(int trackIndex)
- 

getChunkDuration

public long getChunkDuration​(int chunkIndex)
- 

getStartTime

public long getStartTime​(int chunkIndex)
- 

getChunkIndexByPosition

public int getChunkIndexByPosition​(long positionUs)