CallbackMediaItem.Builder

public static final class CallbackMediaItem.Builder
extends MediaItem.Builder

java.lang.Object
   ↳ androidx.media2.common.MediaItem.Builder
     ↳ androidx.media2.common.CallbackMediaItem.Builder


This Builder class simplifies the creation of a CallbackMediaItem object.

Summary

Public constructors

Builder(DataSourceCallback dsc2)

Creates a new Builder object.

Public methods

CallbackMediaItem build()

Build MediaItem.

CallbackMediaItem.Builder setEndPosition(long position)

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

CallbackMediaItem.Builder setMetadata(MediaMetadata metadata)

Set the metadata of this instance.

CallbackMediaItem.Builder setStartPosition(long position)

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

Inherited methods