public class IotHubConnectionString extends IotHubConnectionStringBuilder
Modifier and Type | Field and Description |
---|---|
protected AuthenticationMethod |
authenticationMethod |
protected static String |
HOST_NAME_PROPERTY_NAME |
protected static String |
HOST_NAME_SEPARATOR |
protected String |
hostName |
protected String |
iotHubName |
protected static String |
SHARED_ACCESS_KEY_NAME_PROPERTY_NAME |
protected static String |
SHARED_ACCESS_KEY_PROPERTY_NAME |
protected static String |
SHARED_ACCESS_SIGNATURE_PROPERTY_NAME |
protected String |
sharedAccessKey |
protected String |
sharedAccessKeyName |
protected String |
sharedAccessSignature |
protected static String |
VALUE_PAIR_DELIMITER |
protected static String |
VALUE_PAIR_SEPARATOR |
Modifier | Constructor and Description |
---|---|
protected |
IotHubConnectionString() |
Modifier and Type | Method and Description |
---|---|
AuthenticationMethod |
getAuthenticationMethod()
Getter for authenticationMethod
|
String |
getHostName()
Getter for hostName
|
String |
getIotHubName()
Getter for iotHubName
|
String |
getSharedAccessKey()
Getter for sharedAccessKey
|
String |
getSharedAccessKeyName()
Getter for sharedAccessKeyName
|
String |
getSharedAccessSignature()
Getter for sharedAccessSignature
|
URL |
getUrlApplyConfigurationContent(String deviceId)
Create the url needed to apply some configuration content to a device
|
URL |
getUrlConfiguration(String configurationId)
Create url for requesting configuration data
|
URL |
getUrlConfigurationsList(Integer maxCount)
Create url for requesting configuration data
|
URL |
getUrlCreateExportImportJob()
Create url for processing a bulk import/export job
|
URL |
getUrlDevice(String deviceId)
Create url for requesting device data
|
URL |
getUrlDeviceList(Integer maxCount)
Create url for requesting device list
|
URL |
getUrlDeviceStatistics()
Create url for requesting device statistics
|
URL |
getUrlImportExportJob(String jobId) |
URL |
getUrlJobs(String jobId)
Create url for requesting jobs
|
URL |
getUrlJobsCancel(String jobId)
Create url for cancelling jobs
|
URL |
getUrlMethod(String deviceId)
Create url for requesting device method
|
URL |
getUrlModule(String deviceId,
String moduleId)
Create url for requesting module data
|
URL |
getUrlModuleMethod(String deviceId,
String moduleId)
Create url for requesting device method for module
|
URL |
getUrlModulesOnDevice(String deviceId)
Create url for requesting all modules data on a device
|
URL |
getUrlModuleTwin(String deviceId,
String moduleId)
Create url for requesting module twin
|
URL |
getUrlQuery(String jobType,
String jobStatus)
Create url for querying
|
URL |
getUrlTwin(String deviceId)
Create url for requesting device twin
|
URL |
getUrlTwinQuery()
Create url for querying twin
|
String |
getUserString()
Serialize user string
|
protected void |
setSharedAccessKey(String sharedAccessKey)
Setter for sharedAccessKey
|
protected void |
setSharedAccessKeyName(String sharedAccessKeyName)
Setter for sharedAccessKeyName
|
protected void |
setSharedAccessSignature(String sharedAccessSignature)
Setter for sharedAccessSignature
|
String |
toString()
Serialize connection string
|
createConnectionString, createConnectionString, parse, parseIotHubName, setAuthenticationMethod, setHostName, validate, validateFormat, validateFormatIfSpecified
protected static final String VALUE_PAIR_DELIMITER
protected static final String VALUE_PAIR_SEPARATOR
protected static final String HOST_NAME_SEPARATOR
protected static final String HOST_NAME_PROPERTY_NAME
protected static final String SHARED_ACCESS_KEY_NAME_PROPERTY_NAME
protected static final String SHARED_ACCESS_KEY_PROPERTY_NAME
protected static final String SHARED_ACCESS_SIGNATURE_PROPERTY_NAME
protected String hostName
protected String iotHubName
protected AuthenticationMethod authenticationMethod
protected String sharedAccessKeyName
protected String sharedAccessKey
protected String sharedAccessSignature
public String getUserString()
public URL getUrlMethod(String deviceId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the deviceMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlModuleMethod(String deviceId, String moduleId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the devicemoduleId
- The name of the moduleMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlJobs(String jobId) throws MalformedURLException, IllegalArgumentException
jobId
- is the name of the jobMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if job id is null or emptypublic URL getUrlTwinQuery() throws MalformedURLException
MalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringpublic URL getUrlQuery(String jobType, String jobStatus) throws MalformedURLException
jobStatus
- jobStatus as StringjobType
- jobType as StringMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringpublic URL getUrlJobsCancel(String jobId) throws MalformedURLException, IllegalArgumentException
jobId
- is the name of the jobMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if job id is null or emptypublic URL getUrlTwin(String deviceId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the deviceMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlModuleTwin(String deviceId, String moduleId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the devicemoduleId
- The name of the deviceMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlDevice(String deviceId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the deviceMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlModule(String deviceId, String moduleId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the devicemoduleId
- The name of the deviceMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlApplyConfigurationContent(String deviceId) throws MalformedURLException, IllegalArgumentException
deviceId
- The device to apply the configuration content toMalformedURLException
- if the deviceId contains unexpected characters, and a URL cannot be constructed using itIllegalArgumentException
- if deviceId is null or emptypublic URL getUrlConfiguration(String configurationId) throws MalformedURLException, IllegalArgumentException
configurationId
- The name of the configurationMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlConfigurationsList(Integer maxCount) throws MalformedURLException, IllegalArgumentException
maxCount
- The maximum number of configuration data to returnMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlModulesOnDevice(String deviceId) throws MalformedURLException, IllegalArgumentException
deviceId
- The name of the deviceMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if device id is null or emptypublic URL getUrlDeviceList(Integer maxCount) throws MalformedURLException, IllegalArgumentException
maxCount
- The number of requested devicesMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringIllegalArgumentException
- This exception is thrown if maxCount is null or emptypublic URL getUrlDeviceStatistics() throws MalformedURLException
MalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringpublic URL getUrlCreateExportImportJob() throws MalformedURLException
MalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringpublic URL getUrlImportExportJob(String jobId) throws MalformedURLException
jobId
- Create url for retrieving a bulk import/export jobMalformedURLException
- This exception is thrown if the URL creation failed due to malformed stringpublic String toString()
public String getIotHubName()
public AuthenticationMethod getAuthenticationMethod()
public String getSharedAccessKeyName()
public String getSharedAccessKey()
public String getSharedAccessSignature()
public String getHostName()
protected void setSharedAccessKeyName(String sharedAccessKeyName)
sharedAccessKeyName
- The value of the signature to setprotected void setSharedAccessKey(String sharedAccessKey)
sharedAccessKey
- The value of the signature to setprotected void setSharedAccessSignature(String sharedAccessSignature)
sharedAccessSignature
- The value of the signature to setCopyright © 2020. All rights reserved.