Skip to content

Most visited

Recently visited

navigation
added in version 22.1.0
belongs to Maven artifact com.android.support:mediarouter-v7:27.0.0

MediaRouteDiscoveryRequest

public final class MediaRouteDiscoveryRequest
extends Object

java.lang.Object
   ↳ android.support.v7.media.MediaRouteDiscoveryRequest


Describes the kinds of routes that the media router would like to discover and whether to perform active scanning.

This object is immutable once created.

Summary

Public constructors

MediaRouteDiscoveryRequest(MediaRouteSelector selector, boolean activeScan)

Creates a media route discovery request.

Public methods

Bundle asBundle()

Converts this object to a bundle for serialization.

boolean equals(Object o)
static MediaRouteDiscoveryRequest fromBundle(Bundle bundle)

Creates an instance from a bundle.

MediaRouteSelector getSelector()

Gets the route selector that specifies the kinds of routes to discover.

int hashCode()
boolean isActiveScan()

Returns true if active scanning should be performed.

boolean isValid()

Returns true if the discovery request has all of the required fields.

String toString()

Inherited methods

From class java.lang.Object

Public constructors

MediaRouteDiscoveryRequest

added in version 22.1.0
MediaRouteDiscoveryRequest (MediaRouteSelector selector, 
                boolean activeScan)

Creates a media route discovery request.

Parameters
selector MediaRouteSelector: The route selector that specifies the kinds of routes to discover.

activeScan boolean: True if active scanning should be performed.

Public methods

asBundle

added in version 22.1.0
Bundle asBundle ()

Converts this object to a bundle for serialization.

Returns
Bundle The contents of the object represented as a bundle.

equals

boolean equals (Object o)

Parameters
o Object

Returns
boolean

fromBundle

added in version 22.1.0
MediaRouteDiscoveryRequest fromBundle (Bundle bundle)

Creates an instance from a bundle.

Parameters
bundle Bundle: The bundle, or null if none.

Returns
MediaRouteDiscoveryRequest The new instance, or null if the bundle was null.

getSelector

added in version 22.1.0
MediaRouteSelector getSelector ()

Gets the route selector that specifies the kinds of routes to discover.

Returns
MediaRouteSelector

hashCode

int hashCode ()

Returns
int

isActiveScan

added in version 22.1.0
boolean isActiveScan ()

Returns true if active scanning should be performed.

Returns
boolean

See also:

isValid

added in version 22.1.0
boolean isValid ()

Returns true if the discovery request has all of the required fields.

Returns
boolean

toString

String toString ()

Returns
String

This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields

Hooray!

Follow Google Developers on WeChat

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience.
(Sep 2017 survey)