CallbackMediaItem

Added in 1.0.0
Deprecated in 1.3.0

public class CallbackMediaItem extends MediaItem


Structure for media item descriptor for DataSourceCallback.

Users should use Builder to create CallbackMediaItem.

You cannot directly send this object across the process through ParcelUtils. See MediaItem for detail.

See also
MediaItem

Summary

Nested types

public final class CallbackMediaItem.Builder extends MediaItem.Builder

This class is deprecated.

androidx.media2 is deprecated.

Public methods

@NonNull DataSourceCallback

Return the DataSourceCallback that implements the callback for the data source of this media item.

Inherited Constants

From androidx.media2.common.MediaItem
static final long
POSITION_UNKNOWN = 576460752303423487

Used when a position is unknown.

Inherited methods

From androidx.media2.common.MediaItem
long

Return the position in milliseconds at which the playback will end.

@Nullable MediaMetadata

Gets the metadata of the media.

long

Return the position in milliseconds at which the playback will start.

void

Sets metadata.

String

Public methods

getDataSourceCallback

Added in 1.0.0
Deprecated in 1.3.0
public @NonNull DataSourceCallback getDataSourceCallback()

Return the DataSourceCallback that implements the callback for the data source of this media item.

Returns
@NonNull DataSourceCallback

the DataSourceCallback that implements the callback for the data source of this media item,