Class DataTypeException
Exception for data type violations, containing diagnostic information.
Inheritance
Namespace: Nuqleon.DataModel.TypeSystem
Assembly: Nuqleon.DataModel.CompilerServices.dll
Syntax
public class DataTypeException : Exception
Constructors
DataTypeException()
Creates a new data type violation exception.
Declaration
public DataTypeException()
DataTypeException(DataTypeError)
Creates a new data type violation exception with the specified diagnostic error object.
Declaration
public DataTypeException(DataTypeError error)
Parameters
Type | Name | Description |
---|---|---|
DataTypeError | error | Diagnostic error object. |
DataTypeException(SerializationInfo, StreamingContext)
Creates a new data type violation exception from serialization information.
Declaration
protected DataTypeException(SerializationInfo info, StreamingContext context)
Parameters
Type | Name | Description |
---|---|---|
System.Runtime.Serialization.SerializationInfo | info | Serialization information. |
System.Runtime.Serialization.StreamingContext | context | Streaming context. |
DataTypeException(String)
Creates a new data type violation exception with the specified error message.
Declaration
public DataTypeException(string message)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Error message. |
DataTypeException(String, Exception)
Creates a new data type violation exception with the specified error message and inner exception.
Declaration
public DataTypeException(string message, Exception inner)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Error message. |
System.Exception | inner | Inner exception. |
Properties
Error
Gets the diagnostic error object describing the data type violation.
Declaration
public DataTypeError Error { get; }
Property Value
Type | Description |
---|---|
DataTypeError |
Methods
GetObjectData(SerializationInfo, StreamingContext)
Serializes the object instance to the specified serialization info object.
Declaration
public override void GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
Type | Name | Description |
---|---|---|
System.Runtime.Serialization.SerializationInfo | info | Serialization info. |
System.Runtime.Serialization.StreamingContext | context | Streaming context. |
ToString()
Returns a friendly string representation of the error.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | Friendly string representation of the error. |