public class Twin extends Object
The object is a representation of a module twin if and only if the moduleId is set.
| Constructor and Description |
|---|
Twin()
Constructor to create an instance for a device.
|
Twin(String deviceId)
Constructor to create instance for a device.
|
Twin(String deviceId,
String moduleId)
Constructor to create an instance for a module.
|
| Modifier and Type | Method and Description |
|---|---|
static Twin |
fromJson(String json) |
TwinCollection |
getDesiredProperties()
Getter to get the desired properties setter.
|
TwinCollection |
getReportedProperties()
Getter to get reported properties setter.
|
TwinCollection |
getTags()
Getter for the twin tags.
|
String |
toString()
String representation for this device containing device Id, tags, desired and reported properties.
|
public Twin()
public Twin(String deviceId) throws IllegalArgumentException
deviceId - Id for this device.IllegalArgumentException - This exception is thrown if the device Id is null or emptypublic Twin(String deviceId, String moduleId) throws IllegalArgumentException
deviceId - Id for this device.moduleId - Id for this device's module.IllegalArgumentException - This exception is thrown if the device id is null or empty.public TwinCollection getTags()
public TwinCollection getDesiredProperties()
public TwinCollection getReportedProperties()
Copyright © 2024. All rights reserved.