public class DefaultDeviceDescription extends AbstractDescription implements DeviceDescription
Constructor and Description |
---|
DefaultDeviceDescription(DeviceDescription base,
boolean defaultAvailable,
SparseAnnotations... annotations)
Creates a device description using the supplied information.
|
DefaultDeviceDescription(DeviceDescription base,
Device.Type type,
SparseAnnotations... annotations)
Creates a device description using the supplied information.
|
DefaultDeviceDescription(DeviceDescription base,
SparseAnnotations... annotations)
Creates a device description using the supplied information.
|
DefaultDeviceDescription(java.net.URI uri,
Device.Type type,
java.lang.String manufacturer,
java.lang.String hwVersion,
java.lang.String swVersion,
java.lang.String serialNumber,
ChassisId chassis,
boolean defaultAvailable,
SparseAnnotations... annotations)
Creates a device description using the supplied information.
|
DefaultDeviceDescription(java.net.URI uri,
Device.Type type,
java.lang.String manufacturer,
java.lang.String hwVersion,
java.lang.String swVersion,
java.lang.String serialNumber,
ChassisId chassis,
SparseAnnotations... annotations)
Creates a device description using the supplied information.
|
Modifier and Type | Method and Description |
---|---|
ChassisId |
chassisId()
Returns a device chassis id.
|
java.net.URI |
deviceUri()
Protocol/provider specific URI that can be used to encode the identity
information required to communicate with the device externally, e.g.
|
boolean |
equals(java.lang.Object object) |
int |
hashCode() |
java.lang.String |
hwVersion()
Returns the device hardware version.
|
boolean |
isDefaultAvailable()
Return whether device should be made available by default.
|
java.lang.String |
manufacturer()
Returns the device manufacturer name.
|
java.lang.String |
serialNumber()
Returns the device serial number.
|
java.lang.String |
swVersion()
Returns the device software version.
|
java.lang.String |
toString() |
Device.Type |
type()
Returns the type of the infrastructure device.
|
annotations
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
annotations
public DefaultDeviceDescription(java.net.URI uri, Device.Type type, java.lang.String manufacturer, java.lang.String hwVersion, java.lang.String swVersion, java.lang.String serialNumber, ChassisId chassis, SparseAnnotations... annotations)
uri
- device URItype
- device typemanufacturer
- device manufacturerhwVersion
- device HW versionswVersion
- device SW versionserialNumber
- device serial numberchassis
- chassis idannotations
- optional key/value annotations mappublic DefaultDeviceDescription(java.net.URI uri, Device.Type type, java.lang.String manufacturer, java.lang.String hwVersion, java.lang.String swVersion, java.lang.String serialNumber, ChassisId chassis, boolean defaultAvailable, SparseAnnotations... annotations)
uri
- device URItype
- device typemanufacturer
- device manufacturerhwVersion
- device HW versionswVersion
- device SW versionserialNumber
- device serial numberchassis
- chassis iddefaultAvailable
- optional whether device is by default availableannotations
- optional key/value annotations mappublic DefaultDeviceDescription(DeviceDescription base, SparseAnnotations... annotations)
base
- DeviceDescription to basic informationannotations
- Annotations to use.public DefaultDeviceDescription(DeviceDescription base, Device.Type type, SparseAnnotations... annotations)
base
- DeviceDescription to basic information (except for type)type
- device typeannotations
- Annotations to use.public DefaultDeviceDescription(DeviceDescription base, boolean defaultAvailable, SparseAnnotations... annotations)
base
- DeviceDescription to basic information (except for defaultAvailable)defaultAvailable
- whether device should be made available by defaultannotations
- Annotations to use.public java.net.URI deviceUri()
DeviceDescription
deviceUri
in interface DeviceDescription
public Device.Type type()
DeviceDescription
type
in interface DeviceDescription
public java.lang.String manufacturer()
DeviceDescription
manufacturer
in interface DeviceDescription
public java.lang.String hwVersion()
DeviceDescription
hwVersion
in interface DeviceDescription
public java.lang.String swVersion()
DeviceDescription
swVersion
in interface DeviceDescription
public java.lang.String serialNumber()
DeviceDescription
serialNumber
in interface DeviceDescription
public ChassisId chassisId()
DeviceDescription
chassisId
in interface DeviceDescription
public boolean isDefaultAvailable()
DeviceDescription
isDefaultAvailable
in interface DeviceDescription
public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class AbstractDescription
public boolean equals(java.lang.Object object)
equals
in class AbstractDescription