Index
All Classes and Interfaces|All Packages|Constant Field Values
A
- acceptConnection(MediaSession, MediaSession.ControllerInfo) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.AllowedCommandProvider
-
Called to query whether to allow connection from the controller.
- acceptConnection(MediaSession, MediaSession.ControllerInfo) - Method in class com.castlabs.sdk.mediasession.SessionCallbackBuilder.DefaultAllowedCommandProvider
C
- com.castlabs.sdk.mediasession - package com.castlabs.sdk.mediasession
D
- DEFAULT_SEEK_TIMEOUT_MS - Static variable in class com.castlabs.sdk.mediasession.SessionCallbackBuilder
-
Default timeout value for
SessionCallbackBuilder.setSeekTimeoutMs(int)
. - DefaultAllowedCommandProvider(Context) - Constructor for class com.castlabs.sdk.mediasession.SessionCallbackBuilder.DefaultAllowedCommandProvider
- disableMediaSession(PlayerController) - Static method in class com.castlabs.sdk.mediasession.MediaSessionPlugin
-
Closes Media Session
E
- enableMediaSession(PlayerController) - Static method in class com.castlabs.sdk.mediasession.MediaSessionPlugin
-
Creates and enables Media Session with default configuration.
- enableMediaSession(PlayerController, MediaSessionBuilder) - Static method in class com.castlabs.sdk.mediasession.MediaSessionPlugin
-
Creates and enables Media Session with custom configuration.
G
- getAllowedCommands(MediaSession, MediaSession.ControllerInfo, SessionCommandGroup) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.AllowedCommandProvider
-
Called to query allowed commands in following cases: A
MediaController
requests to connect, and allowed commands is required to tell initial allowed commands. - getAllowedCommands(MediaSession, MediaSession.ControllerInfo, SessionCommandGroup) - Method in class com.castlabs.sdk.mediasession.SessionCallbackBuilder.DefaultAllowedCommandProvider
- getCustomCommands(MediaSession, MediaSession.ControllerInfo) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.CustomCommandProvider
-
Returns a
SessionCommandGroup
with custom commands to publish to the controller, ornull
if no custom commands should be published. - getId() - Method in class com.castlabs.sdk.mediasession.MediaSessionPlugin
- getMediaSession(PlayerController) - Static method in class com.castlabs.sdk.mediasession.MediaSessionPlugin
-
Gets Media Session instance e.g.
I
- isEnabled(PlayerController) - Static method in class com.castlabs.sdk.mediasession.MediaSessionPlugin
-
Checks if Media Session is enabled
M
- MediaIdMediaItemProvider() - Constructor for class com.castlabs.sdk.mediasession.SessionCallbackBuilder.MediaIdMediaItemProvider
- MediaSessionBuilder - Class in com.castlabs.sdk.mediasession
-
Media Session builder allowing customizations
- MediaSessionBuilder() - Constructor for class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Constructs default MediaSessionBuilder
- MediaSessionPlugin - Class in com.castlabs.sdk.mediasession
-
MediaSessionPlugin integrates castLabs Player SDK with AndroidX Media2 session APIs.
- MediaSessionPlugin() - Constructor for class com.castlabs.sdk.mediasession.MediaSessionPlugin
-
Constructs default MediaSessionPlugin
O
- onCommandRequest(MediaSession, MediaSession.ControllerInfo, SessionCommand) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.AllowedCommandProvider
-
Called when a
MediaController
has called an API that controlsSessionPlayer
set to theMediaSession
. - onCommandRequest(MediaSession, MediaSession.ControllerInfo, SessionCommand) - Method in class com.castlabs.sdk.mediasession.SessionCallbackBuilder.DefaultAllowedCommandProvider
- onCreateMediaItem(MediaSession, MediaSession.ControllerInfo, String) - Method in class com.castlabs.sdk.mediasession.SessionCallbackBuilder.MediaIdMediaItemProvider
- onCreateMediaItem(MediaSession, MediaSession.ControllerInfo, String) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.MediaItemProvider
-
Called when
MediaSession.SessionCallback.onCreateMediaItem(MediaSession, ControllerInfo, String)
is called. - onCustomCommand(MediaSession, MediaSession.ControllerInfo, SessionCommand, Bundle) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.CustomCommandProvider
-
Called when a controller has sent a custom command.
- onDisconnected(MediaSession, MediaSession.ControllerInfo) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.DisconnectedCallback
-
Called when the specified controller is disconnected.
- onPostConnect(MediaSession, MediaSession.ControllerInfo) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.PostConnectCallback
-
Called after the specified controller is connected, and you need extra initialization.
- onSetRating(MediaSession, MediaSession.ControllerInfo, String, Rating) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.RatingCallback
-
Called when the specified controller has set a rating for the specified media id.
- onSkipBackward(MediaSession, MediaSession.ControllerInfo) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.SkipCallback
-
Called when the specified controller has sent skip backward.
- onSkipForward(MediaSession, MediaSession.ControllerInfo) - Method in interface com.castlabs.sdk.mediasession.SessionCallbackBuilder.SkipCallback
-
Called when the specified controller has sent skip forward.
S
- SessionCallbackBuilder - Class in com.castlabs.sdk.mediasession
-
Builds a
MediaSession.SessionCallback
with various collaborators. - SessionCallbackBuilder.AllowedCommandProvider - Interface in com.castlabs.sdk.mediasession
-
Provides allowed commands for
MediaController
. - SessionCallbackBuilder.CustomCommandProvider - Interface in com.castlabs.sdk.mediasession
-
Callbacks for querying what custom commands are supported, and for handling a custom command when a controller sends it.
- SessionCallbackBuilder.DefaultAllowedCommandProvider - Class in com.castlabs.sdk.mediasession
-
Default implementation of
SessionCallbackBuilder.AllowedCommandProvider
that behaves as follows: Accepts connection requests from controller if any of the following conditions are met: Controller is in the same package as the session. - SessionCallbackBuilder.DisconnectedCallback - Interface in com.castlabs.sdk.mediasession
-
Callback for handling controller disconnection.
- SessionCallbackBuilder.MediaIdMediaItemProvider - Class in com.castlabs.sdk.mediasession
-
A
SessionCallbackBuilder.MediaItemProvider
that creates media items containing only a media ID. - SessionCallbackBuilder.MediaItemProvider - Interface in com.castlabs.sdk.mediasession
-
Provides the
MediaItem
. - SessionCallbackBuilder.PostConnectCallback - Interface in com.castlabs.sdk.mediasession
-
Callback for handling extra initialization after the connection.
- SessionCallbackBuilder.RatingCallback - Interface in com.castlabs.sdk.mediasession
-
Callback receiving a user rating for a specified media id.
- SessionCallbackBuilder.SkipCallback - Interface in com.castlabs.sdk.mediasession
-
Callback receiving skip backward and skip forward.
- setAllowedCommandProvider(SessionCallbackBuilder.AllowedCommandProvider) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.AllowedCommandProvider
to provide allowed commands for controllers - setCustomCommandProvider(SessionCallbackBuilder.CustomCommandProvider) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.CustomCommandProvider
to handle incoming custom commands - setDisconnectedCallback(SessionCallbackBuilder.DisconnectedCallback) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.DisconnectedCallback
to handle cleaning up controller - setFastForwardIncrementMs(int) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the fast forward increment in milliseconds
- setMediaItemProvider(SessionCallbackBuilder.MediaItemProvider) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.MediaItemProvider
that will convert media ids toMediaItems
- setPostConnectCallback(SessionCallbackBuilder.PostConnectCallback) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.PostConnectCallback
to handle extra initialization after the connection - setRatingCallback(SessionCallbackBuilder.RatingCallback) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.RatingCallback
to handle user ratings - setRewindIncrementMs(int) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the rewind increment in milliseconds
- setSeekTimeoutMs(int) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the timeout in milliseconds for fast forward and rewind operations, or
0
for no timeout. - setSkipCallback(SessionCallbackBuilder.SkipCallback) - Method in class com.castlabs.sdk.mediasession.MediaSessionBuilder
-
Sets the
SessionCallbackBuilder.SkipCallback
to handle skip backward and skip forward - setTrustedPackageNames(List<String>) - Method in class com.castlabs.sdk.mediasession.SessionCallbackBuilder.DefaultAllowedCommandProvider
-
Sets the package names from which the session will accept incoming connections.
All Classes and Interfaces|All Packages|Constant Field Values