public class Module extends BaseDevice
| Modifier and Type | Field and Description |
|---|---|
protected String |
id
Module name
A case-sensitive string (up to 128 char long)
of ASCII 7-bit alphanumeric chars
+ {'-', ':', '.', '+', '%', '_', '#', '*', '?', '!', '(', ')', ',', '=', '@', ';', '$', '''}.
|
protected String |
managedBy
Specifies the module's managed by owner
|
cloudToDeviceMessageCount, connectionState, connectionStateUpdatedTime, deviceId, eTag, generationId, lastActivityTime, OFFSET_TIME_DEFAULT, UTC_TIME_DEFAULT| Modifier | Constructor and Description |
|---|---|
protected |
Module(String deviceId,
String moduleId,
SymmetricKey symmetricKey)
Create an Module instance using the given module name
|
| Modifier and Type | Method and Description |
|---|---|
static Module |
createFromId(String deviceId,
String moduleId,
SymmetricKey symmetricKey)
Static create function
Creates module object using the given name.
|
static Module |
createModule(String deviceId,
String moduleId,
AuthenticationType authenticationType)
Static create function
Creates device object using the given name that will use a Certificate Authority signed certificate for authentication.
|
String |
getId()
Getter for module name
|
String |
getManagedBy()
Getter for module's managed by owner
|
getAuthenticationType, getCloudToDeviceMessageCount, getConnectionState, getConnectionStateUpdatedTime, getDeviceId, geteTag, getGenerationId, getLastActivityTime, getPrimaryKey, getPrimaryThumbprint, getSecondaryKey, getSecondaryThumbprint, getSymmetricKey, setForceUpdate, setSymmetricKey, setThumbprint, setThumbprintFinalprotected String id
protected String managedBy
protected Module(String deviceId, String moduleId, SymmetricKey symmetricKey) throws IllegalArgumentException
deviceId - Name of the device (used as device id)moduleId - - ame of the module (used as module id)symmetricKey - - Device key. If parameter is null, then the key will be auto generated.IllegalArgumentException - This exception is thrown if deviceId or moduleId is null or empty.public static Module createFromId(String deviceId, String moduleId, SymmetricKey symmetricKey) throws IllegalArgumentException
deviceId - - String containing the device namemoduleId - - String containing the module namesymmetricKey - - Device key. If parameter is null, then the key will be auto generated.IllegalArgumentException - This exception is thrown if deviceId is null or empty.public static Module createModule(String deviceId, String moduleId, AuthenticationType authenticationType) throws IllegalArgumentException
deviceId - - String containing the device namemoduleId - - String containing the module nameauthenticationType - - The type of authentication used by this device.IllegalArgumentException - This exception is thrown if deviceId or moduleId is null or empty.public String getId()
public String getManagedBy()
Copyright © 2022. All rights reserved.