Class NativeApiException
The exception that is thrown when an error occurred in the native MIDI API.
Implements
Inherited Members
Namespace: Melanchall.DryWetMidi.Common
Assembly: Melanchall.DryWetMidi.dll
Syntax
public sealed class NativeApiException : MidiException, ISerializable
Constructors
NativeApiException()
Initializes a new instance of the NativeApiException.
Declaration
public NativeApiException()
NativeApiException(string)
Initializes a new instance of the NativeApiException with the
specified error message.
Declaration
public NativeApiException(string message)
Parameters
| Type | Name | Description |
|---|---|---|
| string | message | The error message that explains the reason for the exception. |
NativeApiException(string, Exception)
Initializes a new instance of the NativeApiException class with the
specified error message and a reference to the inner exception that is the
cause of this exception.
Declaration
public NativeApiException(string message, Exception innerException)
Parameters
| Type | Name | Description |
|---|---|---|
| string | message | The error message that explains the reason for the exception. |
| Exception | innerException | The exception that is the cause of the current exception,
or a null reference if no inner exception is specified. |
NativeApiException(string, int, int)
Initializes a new instance of the NativeApiException class with the
specified error message and an error code.
Declaration
public NativeApiException(string message, int mainErrorCode, int additionalErrorCode)
Parameters
| Type | Name | Description |
|---|---|---|
| string | message | The error message that explains the reason for the exception. |
| int | mainErrorCode | The error code. |
| int | additionalErrorCode |
Properties
AdditionalErrorCode
Declaration
public int? AdditionalErrorCode { get; }
Property Value
| Type | Description |
|---|---|
| int? |
MainErrorCode
Gets the code of an error represented by the current NativeApiException.
Declaration
public int? MainErrorCode { get; }
Property Value
| Type | Description |
|---|---|
| int? |