java.lang.Object | |
↳ | android.media.MediaRouter.RouteInfo |
Known Direct Subclasses |
Information about a media route.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | PLAYBACK_TYPE_LOCAL | The default playback type, "local", indicating the presentation of the media is happening on the same device (e.g. | |||||||||
int | PLAYBACK_TYPE_REMOTE | A playback type indicating the presentation of the media is happening on a different device (i.e. | |||||||||
int | PLAYBACK_VOLUME_FIXED | Playback information indicating the playback volume is fixed, i.e. | |||||||||
int | PLAYBACK_VOLUME_VARIABLE | Playback information indicating the playback volume is variable and can be controlled from this object. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Get the icon representing this route.
| |||||||||||
Return the properly localized/resource selected name of this route.
| |||||||||||
Return the current volume for this route.
| |||||||||||
Request a volume change for this route.
| |||||||||||
Request an incremental volume update for this route.
| |||||||||||
Set an application-specific tag object for this route.
| |||||||||||
Returns a string containing a concise, human-readable description of this
object.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
The default playback type, "local", indicating the presentation of the media is happening on the same device (e.g. a phone, a tablet) as where it is controlled from.
A playback type indicating the presentation of the media is happening on a different device (i.e. the remote device) than where it is controlled from.
Playback information indicating the playback volume is fixed, i.e. it cannot be controlled from this object. An example of fixed playback volume is a remote player, playing over HDMI where the user prefers to control the volume on the HDMI sink, rather than attenuate at the source.
Playback information indicating the playback volume is variable and can be controlled from this object.
Get the icon representing this route. This icon will be used in picker UIs if available.
Return the properly localized/resource selected name of this route.
context | Context used to resolve the correct configuration to load |
---|
Return the current volume for this route. Depending on the route, this may only be valid if the route is currently selected.
Request a volume change for this route.
volume | value between 0 and getVolumeMax |
---|
Request an incremental volume update for this route.
direction | Delta to apply to the current volume |
---|
Set an application-specific tag object for this route. The application may use this to store arbitrary data associated with the route for internal tracking.
Note that the lifespan of a route may be well past the lifespan of an Activity or other Context; take care that objects you store here will not keep more data in memory alive than you intend.
tag | Arbitrary, app-specific data for this route to hold for later use |
---|
Returns a string containing a concise, human-readable description of this object. Subclasses are encouraged to override this method and provide an implementation that takes into account the object's type and data. The default implementation is equivalent to the following expression:
getClass().getName() + '@' + Integer.toHexString(hashCode())
See Writing a useful
toString
method
if you intend implementing your own toString
method.