public abstract class Device
extends java.lang.Object
Device lists the characteristics of a device.| Modifier and Type | Class and Description |
|---|---|
static class |
Device.Field
The Field enum defines the characteristics of a device.
|
static class |
Device.Location
The
Device.Location describes the location of a device. |
| Modifier and Type | Method and Description |
|---|---|
abstract java.util.List<java.lang.String> |
getDeviceModels()
Get the list of device models supported by this device.
|
abstract java.lang.String |
getId()
Get the device identifier.
|
abstract Device.Location |
getLocation()
Return the device location.
|
abstract java.util.Map<java.lang.String,java.lang.String> |
getMetadata()
Return the device metadata.
|
abstract java.lang.String |
getMetadata(java.lang.String key)
Return the value of the metadata field
key. |
abstract java.lang.String |
getValue(Device.Field field)
Get the value of the specified
field or an empty String if the value is unknown. |
abstract boolean |
isDirectlyConnected()
Return whether the device is directly connected to the server or is connected through a gateway.
|
public abstract java.util.List<java.lang.String> getDeviceModels()
public abstract java.lang.String getValue(Device.Field field)
field or an empty String if the value is unknown.field - the field to look forpublic abstract boolean isDirectlyConnected()
true if the device is directly connected, false otherwise.public abstract java.lang.String getId()
public abstract java.util.Map<java.lang.String,java.lang.String> getMetadata()
public abstract java.lang.String getMetadata(java.lang.String key)
key.key - the metadata key to returnkey or null if not found.public abstract Device.Location getLocation()