BindException Class
Indicates that an error occurred during XML deserialization, binding, or configuration validation.
public sealed class BindException : Exception
- Inheritance
- Implements
Remarks
This exception is thrown when Oxbind fails to bind XML data to a target class, for example, when the XML structure does not match the expected schema defined by the constructor parameters of the target class.
Constructors
|
Bind |
Initializes a new instance of the BindException class. |
|
Bind |
Initializes a new instance of the BindException class, with the specified detail message. |
|
Bind |
Initializes a new instance of the BindException class, with the specified detail message and cause. |
|
Bind |
Initializes a new instance of the BindException class, with the specified detail message and the specified location. |
|
Bind |
Initializes a new instance of the BindException class, with the specified detail message and cause. |
Properties
|
Line |
Gets the line information. |
| Data | (Inherited from Exception) |
| HelpLink | (Inherited from Exception) |
| HResult | (Inherited from Exception) |
| InnerException | (Inherited from Exception) |
| Message | (Inherited from Exception) |
| Source | (Inherited from Exception) |
| StackTrace | (Inherited from Exception) |
| TargetSite | (Inherited from Exception) |
Methods
|
Get |
Gets the message with the location information. |
| GetBaseException() | (Inherited from Exception) |
| GetObjectData(SerializationInfo, StreamingContext) | (Inherited from Exception) |
| GetType() | (Inherited from Exception) |
| ToString() | (Inherited from Exception) |
| Equals(object) | (Inherited from object) |
| GetHashCode() | (Inherited from object) |
| GetType() | (Inherited from object) |
| MemberwiseClone() | (Inherited from object) |
Constructors Detail
BindException()
Initializes a new instance of the BindException class.
public BindException()
Remarks
The LineInfo property is initialized to represent no line information.
BindException(string)
Initializes a new instance of the BindException class, with the specified detail message.
public BindException(string message)
Parameters
- message
- string
The detail message.
Remarks
The LineInfo property is initialized to represent no line information.
BindException(string, Exception)
Initializes a new instance of the BindException class, with the specified detail message and cause.
public BindException(string message, Exception innerException)
Parameters
- message
- string
The detail message.
- innerException
- Exception
The cause.
Remarks
The LineInfo property is initialized to represent no line information.
BindException(string, IXmlLineInfo)
Initializes a new instance of the BindException class, with the specified detail message and the specified location.
public BindException(string message, IXmlLineInfo info)
Parameters
- message
- string
The detail message.
- info
-
IXml
Line Info
The line information.
BindException(string, Exception, IXmlLineInfo)
Initializes a new instance of the BindException class, with the specified detail message and cause.
public BindException(string message, Exception innerException, IXmlLineInfo info)
Parameters
- message
- string
The detail message.
- innerException
- Exception
The cause.
- info
-
IXml
Line Info
The line information.
Properties Detail
LineInfo
Gets the line information.
public IXmlLineInfo LineInfo { get; }
Property Value
Methods Detail
GetFullMessage()
Gets the message with the location information.
public string GetFullMessage()
Returns
The string representation.
Remarks
This method returns a string in the format
"Line:Column:Message" if LineInfo contains line information (i.e., IXmlLineInfo.HasLineInfo() returns true), otherwise it returns
the same as Exception.Message.