Save the date! Android Dev Summit is coming to Sunnyvale, CA on Oct 23-24, 2019.

Builder

class Builder : BuilderBase<MediaLibraryService2.MediaLibrarySession!, MediaLibraryService2.MediaLibrarySession.Builder!, MediaLibraryService2.MediaLibrarySession.MediaLibrarySessionCallback!>
androidx.media2.MediaLibraryService2.MediaLibrarySession.Builder

Builder for MediaLibrarySession.

Summary

Public constructors
<init>(@NonNull service: MediaLibraryService2, @NonNull callbackExecutor: Executor, @NonNull callback: MediaLibraryService2.MediaLibrarySession.MediaLibrarySessionCallback)

Public methods
MediaLibraryService2.MediaLibrarySession.Builder
setId(@NonNull id: String)

MediaLibraryService2.MediaLibrarySession.Builder
setPlaylistAgent(@NonNull playlistAgent: MediaPlaylistAgent)

MediaLibraryService2.MediaLibrarySession.Builder
setPlayer(@NonNull player: MediaPlayerConnector)

MediaLibraryService2.MediaLibrarySession.Builder

MediaLibraryService2.MediaLibrarySession

Public constructors

<init>

Builder(@NonNull service: MediaLibraryService2, @NonNull callbackExecutor: Executor, @NonNull callback: MediaLibraryService2.MediaLibrarySession.MediaLibrarySessionCallback)

Public methods

setId

@NonNull fun setId(@NonNull id: String): MediaLibraryService2.MediaLibrarySession.Builder

setPlaylistAgent

@NonNull fun setPlaylistAgent(@NonNull playlistAgent: MediaPlaylistAgent): MediaLibraryService2.MediaLibrarySession.Builder

setPlayer

@NonNull fun setPlayer(@NonNull player: MediaPlayerConnector): MediaLibraryService2.MediaLibrarySession.Builder

setSessionActivity

@NonNull fun setSessionActivity(@Nullable pi: PendingIntent?): MediaLibraryService2.MediaLibrarySession.Builder

build

@NonNull fun build(): MediaLibraryService2.MediaLibrarySession