MediaBrowserCompat.SearchCallback


abstract class MediaBrowserCompat.SearchCallback


Callback for receiving the result of search.

Summary

Public constructors

Public functions

Unit
onError(query: String, extras: Bundle!)

Called when an error happens while search or the connected service doesn't support search.

Unit
onSearchResult(
    query: String,
    extras: Bundle!,
    items: (Mutable)List<MediaBrowserCompat.MediaItem!>
)

Called when the search finished successfully.

Public constructors

SearchCallback

Added in 1.1.0
SearchCallback()

Public functions

onError

Added in 1.1.0
fun onError(query: String, extras: Bundle!): Unit

Called when an error happens while search or the connected service doesn't support search.

Parameters
query: String

The search query sent for the search request to the connected service.

extras: Bundle!

The bundle of service-specific arguments sent to the connected service.

onSearchResult

Added in 1.1.0
fun onSearchResult(
    query: String,
    extras: Bundle!,
    items: (Mutable)List<MediaBrowserCompat.MediaItem!>
): Unit

Called when the search finished successfully.

Parameters
query: String

The search query sent for the search request to the connected service.

extras: Bundle!

The bundle of service-specific arguments sent to the connected service.

items: (Mutable)List<MediaBrowserCompat.MediaItem!>

The list of media items which contains the search result.