Saxon.Api
Class ValidationFailure
-
public class ValidationFailure
This object represents a failure detected when validating an instance against a type defined in a schema.
The object holds information about the schema constraints that were violated, and the location in the instance document where the invalidity was detected. It is not an exception, because detection of invalid instances is not considered an abnormal condition and does not cause program termination.
Property Summary |
|
---|---|
int | ColumnNumber Return the character position where the current document event ends. |
string | ConstraintClauseNumber Get the constraint clause number. |
string | ConstraintName Get the constraint name. |
string | ConstraintReference Get the constraint name and clause in the format defined in XML Schema Part C (Outcome Tabulations). This mandates the format validation-rule-name.clause-number |
string | ContextPath Get additional location text, if any. |
string | ErrorCode Get the error code associated with the validity error. This is relevant only when validation is run from within XSLT or XQuery, which define different error codes for validation errors. |
int | LineNumber Return the line number where the current document event ends. |
string | Message Get the text of a message explaining what is wrong. |
string | Path Get a hierarchic path giving the logical position in the instance document where the validation error was found. |
string | PublicId Return the public identifier for the current document event. |
int | SchemaPart Get the "schema part" component of the constraint reference. |
string | SystemId Return the system identifier for the current document event. |
Property Detail
ColumnNumber
Return the character position where the current document event ends.
Returns:
ConstraintClauseNumber
Get the constraint clause number.
Returns:
ConstraintName
Get the constraint name.
Returns:
ConstraintReference
Get the constraint name and clause in the format defined in XML Schema Part C (Outcome Tabulations). This mandates the format validation-rule-name.clause-number
Returns:
ContextPath
Get additional location text, if any.
Returns:
ErrorCode
Get the error code associated with the validity error. This is relevant only when validation is run from within XSLT or XQuery, which define different error codes for validation errors.
Returns:
LineNumber
Return the line number where the current document event ends.
Returns:
Message
Get the text of a message explaining what is wrong.
Returns:
Path
Get a hierarchic path giving the logical position in the instance document where the validation error was found.
Returns:
PublicId
Return the public identifier for the current document event.
Returns:
SchemaPart
Get the "schema part" component of the constraint reference.
Returns:
SystemId
Return the system identifier for the current document event.
Returns: