Share via


IotHubException Class

Definition

The exception that is thrown when an error occurs during DeviceClient or ModuleClient operation.

[System.Serializable]
public class IotHubException : Exception
[<System.Serializable>]
type IotHubException = class
    inherit Exception
Public Class IotHubException
Inherits Exception
Inheritance
IotHubException
Derived
Attributes

Constructors

IotHubException()

Creates an instance of this class with an empty error message.

IotHubException(Exception)

Creates an instance of this class with an empty error message and a reference to the inner exception that caused this exception.

IotHubException(SerializationInfo, StreamingContext)

Creates an instance of this class with the SerializationInfo and StreamingContext associated with the exception.

IotHubException(String)

Creates an instance of this class with the supplied error message and marks it as non-transient.

IotHubException(String, Boolean)

Creates an instance of this class with the supplied error message and a flag indicating if the error was transient.

IotHubException(String, Boolean, String)

Creates an instance of this class with the supplied error message, tracking Id and a flag indicating if the error was transient.

IotHubException(String, Exception)

Creates an instance of this class with a specified error message and a reference to the inner exception that caused this exception, and marks it as non-transient.

IotHubException(String, Exception, Boolean)

Creates an instance of this class with a specified error message, a reference to the inner exception that caused this exception and a flag indicating if the error was transient.

IotHubException(String, Exception, Boolean, String)

Creates an instance of this class with a specified error message, a reference to the inner exception that caused this exception, a flag indicating if the error was transient and the service returned tracking Id associated with this particular error.

IotHubException(String, String)

Creates an instance of this class with the supplied error message and tracking Id, and marks it as non-transient.

Properties

IsTransient

Indicates if the error is transient and should be retried.

TrackingId

The service returned tracking Id associated with this particular error.

Methods

GetObjectData(SerializationInfo, StreamingContext)

Sets the SerializationInfo with information about the exception. Use this to set IsTransient and TrackingId to the serialized object data.

Applies to