Interface MediaSessionConnector.CommandReceiver

    • Method Detail

      • onCommand

        boolean onCommand​(Player player,
                          ControlDispatcher controlDispatcher,
                          String command,
                          @Nullable
                          Bundle extras,
                          @Nullable
                          ResultReceiver cb)
        See MediaSessionCompat.Callback.onCommand(String, Bundle, ResultReceiver). The receiver may handle the command, but is not required to do so. Changes to the player should be made via the ControlDispatcher.
        Parameters:
        player - The player connected to the media session.
        controlDispatcher - A ControlDispatcher that should be used for dispatching changes to the player.
        command - The command name.
        extras - Optional parameters for the command, may be null.
        cb - A result receiver to which a result may be sent by the command, may be null.
        Returns:
        Whether the receiver handled the command.