DeviceInfo
class DeviceInfo
Information about the playback device.
Summary
Nested types |
|---|
class DeviceInfo.BuilderBuilder for |
@DocumentedTypes of playback. |
Constants |
|
|---|---|
const Int |
Playback happens on the local device (e.g. phone). |
const Int |
Playback happens outside of the device (e.g. a cast device). |
const DeviceInfo! |
Unknown DeviceInfo. |
Public constructors |
|---|
@UnstableApiThis function is deprecated. Use |
Public functions |
|
|---|---|
Boolean |
|
java-static DeviceInfo! |
@UnstableApiRestores a |
Int |
hashCode() |
Bundle! |
Public properties |
|
|---|---|
@IntRange(from = 0) Int |
The maximum volume that the device supports, or |
@IntRange(from = 0) Int |
The minimum volume that the device supports. |
Int |
The type of playback. |
String? |
The |
Constants
PLAYBACK_TYPE_LOCAL
const val PLAYBACK_TYPE_LOCAL = 0: Int
Playback happens on the local device (e.g. phone).
PLAYBACK_TYPE_REMOTE
const val PLAYBACK_TYPE_REMOTE = 1: Int
Playback happens outside of the device (e.g. a cast device).
Public constructors
DeviceInfo
@UnstableApiDeviceInfo(
@DeviceInfo.PlaybackType playbackType: Int,
minVolume: @IntRange(from = 0) Int,
maxVolume: @IntRange(from = 0) Int
)
Public functions
fromBundle
@UnstableApi
java-static fun fromBundle(bundle: Bundle!): DeviceInfo!
Restores a DeviceInfo from a Bundle.
Public properties
maxVolume
val maxVolume: @IntRange(from = 0) Int
The maximum volume that the device supports, or 0 if unspecified.
routingControllerId
val routingControllerId: String?
The routing controller id of the associated MediaRouter2.RoutingController, or null if unset or playbackType is PLAYBACK_TYPE_LOCAL.
This id allows mapping this device information to a routing controller, which provides information about the media route and allows controlling its volume.