IotHubException Class
- java.
lang. Object - Exception
- com.
microsoft. azure. sdk. iot. service. exceptions. IotHubException
- com.
public class IotHubException
Super class for IotHub exceptions
Field Summary
Modifier and Type | Field and Description |
---|---|
int |
errorCode
Provides the HTTP error code, if applicable. This value will be a 6 digital error code such as 404001 if the service provided one in response message to the HTTP request. Otherwise it will be a 3 digit status code such as 404. For AMQP operations such as sending cloud to device messages, receiving message feedback, and getting file upload notifications, this field will not be populated. |
Error |
errorCodeDescription
Provides the HTTP error code description, if applicable. For AMQP operations such as sending cloud to device messages, receiving message feedback, and getting file upload notifications, this field will not be populated. |
Constructor Summary
Constructor | Description |
---|---|
IotHubException() |
Instantiate a new IotHubException with no details. |
IotHubException(int errorCode, String message) |
Instantiate a new IotHubException. |
IotHubException(String message) |
Instantiate a new IotHubException. |
Field Details
errorCode
protected int errorCode
Provides the HTTP error code, if applicable.
This value will be a 6 digital error code such as 404001 if the service provided one in response message to the HTTP request. Otherwise it will be a 3 digit status code such as 404.
For AMQP operations such as sending cloud to device messages, receiving message feedback, and getting file upload notifications, this field will not be populated.
errorCodeDescription
protected ErrorCodeDescription errorCodeDescription
Provides the HTTP error code description, if applicable.
For AMQP operations such as sending cloud to device messages, receiving message feedback, and getting file upload notifications, this field will not be populated.
Constructor Details
IotHubException
public IotHubException()
Instantiate a new IotHubException with no details.
IotHubException
public IotHubException(int errorCode, String message)
Instantiate a new IotHubException.
Parameters:
IotHubException
public IotHubException(String message)
Instantiate a new IotHubException.
Parameters:
Applies to
Azure SDK for Java