PriorityDataSource.Factory


public final class PriorityDataSource.Factory implements DataSource.Factory


DataSource.Factory for PriorityDataSource instances.

Summary

Public constructors

Factory(
    DataSource.Factory upstreamFactory,
    PriorityTaskManager priorityTaskManager,
    @C.Priority int priority
)

Creates an instance.

Public methods

PriorityDataSource

Creates a DataSource instance.

Public constructors

Factory

public Factory(
    DataSource.Factory upstreamFactory,
    PriorityTaskManager priorityTaskManager,
    @C.Priority int priority
)

Creates an instance.

Parameters
DataSource.Factory upstreamFactory

A DataSource.Factory that provides upstream DataSources for PriorityDataSource instances created by the factory.

PriorityTaskManager priorityTaskManager

The PriorityTaskManager to which tasks using instances created by this factory will be registered.

@C.Priority int priority

The C.Priority of the tasks using PriorityDataSource instances created by this factory.

Public methods

createDataSource

public PriorityDataSource createDataSource()

Creates a DataSource instance.