FakeAdaptiveDataSet.Factory


public final class FakeAdaptiveDataSet.Factory


Factory for FakeAdaptiveDataSets.

Summary

Public constructors

Factory(
    long chunkDurationUs,
    double bitratePercentStdDev,
    Random random
)

Set up factory for FakeAdaptiveDataSets with a chunk duration and the standard deviation of the chunk size.

Public methods

FakeAdaptiveDataSet
createDataSet(TrackGroup trackGroup, long mediaDurationUs)

Returns a new FakeAdaptiveDataSet for the given TrackGroup.

Public constructors

Factory

public Factory(
    long chunkDurationUs,
    double bitratePercentStdDev,
    Random random
)

Set up factory for FakeAdaptiveDataSets with a chunk duration and the standard deviation of the chunk size.

Parameters
long chunkDurationUs

The chunk duration to use in microseconds.

double bitratePercentStdDev

The standard deviation used to generate the chunk sizes centered around the average bitrate of the Formats. The standard deviation is given in percent (of the average size).

Random random

The random number generator used to generate the chunk size variation.

Public methods

createDataSet

public FakeAdaptiveDataSet createDataSet(TrackGroup trackGroup, long mediaDurationUs)

Returns a new FakeAdaptiveDataSet for the given TrackGroup.

Parameters
TrackGroup trackGroup

The TrackGroup for which the data set is to be created.

long mediaDurationUs

The total duration of the fake data set in microseconds.