Prefetching Repository
This is a meta media repository that performs requests to all possible values of an item as soon as it gets an item it has not seen before. This can be used in combination with a caching repository to perform eager caching.
An exception to this are requests to getTimestampLink()
since actual requests this is rare.
Parameters
a MediaRepository implementation that performs caching
this allows to temporarily disable eager requests. This can be uses when the system is in power saving mode.
the thread this repository should use to perform requests with. This should be the same thad as the one NewPlayer is in.
Constructors
Properties
Functions
This should return the chapters associated with an item. If an item does not have chapters you may return an empty list.
Supply a custom HttpDataSource.Factory. This is important for Youtube.
Get MediaMetadata information for a certain item. Please refer to the media3 documentation for MediaMetadata.
This should return a thumbnail associated with the provided timestamp of the provided item. The reason this function does not simply return a Uri to a bitmap is that some platforms like Youtube provide the preview thumbnail as a collage of multiple thumbnails within one jpeg file. It is then the task of the client to crop this jpeg to only show the piece of that image that depicts the thumbnail for the given timestamp.
The amount of review thumbnails an item provides. This is used to tell async requesting tools how much requests to spawn to get all thumbnails. It's also used to calculate the correct keys for the caching repository.
Returns the information of the repository. Please see the documentation for RepoMetaInfo for more details.
This should return all the Streams associated with an item.
This should return all the Subtitles associated with an item.
Should return the link to a certain timestamp of the video/audio stream associated by item. An example for a timestamp link would be this (don't watch it though its dangerous): https://www.youtube.com/watch?v=H8ZH_mkfPUY&t=19s