ExportImportDevice Class

  • java.lang.Object
    • com.microsoft.azure.sdk.iot.service.registry.ExportImportDevice

public class ExportImportDevice

Constructor Summary

Constructor Description
ExportImportDevice()

Default constructor for an ExportImportDevice object. Randomly generates a device ID and uses a randomly generated shared access signature for authentication

ExportImportDevice(String deviceId, AuthenticationType authenticationType)

Constructor for an ExportImportDevice object.

Method Summary

Modifier and Type Method and Description
AuthenticationMechanism getAuthentication()

Getter for device authentication mechanism.

void setAuthentication(AuthenticationMechanism authentication)

Setter for device authentication mechanism.

Constructor Details

ExportImportDevice

public ExportImportDevice()

Default constructor for an ExportImportDevice object. Randomly generates a device ID and uses a randomly generated shared access signature for authentication

ExportImportDevice

public ExportImportDevice(String deviceId, AuthenticationType authenticationType)

Constructor for an ExportImportDevice object.

Parameters:

deviceId - the id of the new device
authenticationType - the type of authentication to be used. For shared access signature and self signed x.509, all keys shall be generated automatically.

Throws:

IllegalArgumentException - if the provided deviceId or authenticationType is null or empty

Method Details

getAuthentication

public AuthenticationMechanism getAuthentication()

Getter for device authentication mechanism.

Returns:

The device authentication mechanism.

setAuthentication

public void setAuthentication(AuthenticationMechanism authentication)

Setter for device authentication mechanism.

Parameters:

authentication - The device authentication mechanism.

Throws:

IllegalArgumentException - if the provided authentication is null

Applies to