Google is committed to advancing racial equity for Black communities. See how.

MediaQueueRecyclerViewAdapter

public abstract class MediaQueueRecyclerViewAdapter extends Adapter<VH extends RecyclerView.ViewHolder>

A RecyclerView.Adapter for media queue using MediaQueue as backend. The adapter can be used to provide views for a RecyclerView.

Public Constructor Summary

Public Method Summary

void
dispose()
Disposes the adapter so it no longer receives update from MediaQueue.
MediaQueueItem
getItem(int position)
Returns the MediaQueueItem at a given position in the queue.
int
long
getItemId(int position)
MediaQueue
getMediaQueue()
Returns the MediaQueue backing this adapter.

Inherited Method Summary

Public Constructors

public MediaQueueRecyclerViewAdapter (MediaQueue mediaQueue)

Parameters
mediaQueue the MediaQueue object backing this adapter

Public Methods

public void dispose ()

Disposes the adapter so it no longer receives update from MediaQueue.

public MediaQueueItem getItem (int position)

Returns the MediaQueueItem at a given position in the queue.

public int getItemCount ()

public long getItemId (int position)

public MediaQueue getMediaQueue ()

Returns the MediaQueue backing this adapter.