public class ValidationContext extends ConversionRules
DEFAULT
Constructor and Description |
---|
ValidationContext(ConversionRules rules) |
Modifier and Type | Method and Description |
---|---|
AssertionTreeBuilder |
getAssertionTreeBuilder() |
protected ConstraintChecker |
getConstraintChecker()
Get the constraint checker used in this pipeline
|
Controller |
getController()
Get the Controller used for this validation episode
|
protected java.lang.String |
getErrorCode() |
int |
getErrorCount()
Get the number of validation errors found during the validation episode
|
ValidationFailure |
getFirstFailure()
Get details of the first failure that was reported
|
Location |
getInitiatingLocation() |
InvalidityHandler |
getInvalidityHandler()
Get the callback for reporting validation errors
|
StartTagBufferEE |
getStartTagBuffer()
Get the startTagBuffer
|
Sequence<?> |
getValidationErrorObject()
Get the error object.
|
ValidationParams |
getValidationParams()
Get the validation parameters (as declared using saxon:param)
|
SchemaType |
getXSIType()
Get the value of the xsi:type attribute.
|
boolean |
hasValidationParams()
Ask whether there are any validation parameters defined
|
boolean |
incrementErrorCount(ValidationFailure failure)
Increment the count of validation errors found
|
void |
setAssertionTreeBuilder(AssertionTreeBuilder assertionTreeBuilder) |
void |
setConstraintChecker(ConstraintChecker checker)
Set the constraint checker used in this pipeline
|
void |
setController(Controller controller)
Set the Controller used for this validation episode
|
void |
setErrorCode(java.lang.String errorCode)
Set the error code to be used for error messages
|
void |
setErrorLimit(int limit)
Set a limit on the number of errors to be reported before validation is abandoned
|
void |
setInitiatingLocation(Location initiatingLocation) |
void |
setInvalidityHandler(InvalidityHandler invalidityHandler)
Set the callback for reporting validation errors
|
void |
setStartTagBuffer(StartTagBufferEE startTag)
Set the StartTagBuffer, which buffers attributes on the element start tag, and also acts as
the namespaceResolver to be used for resolving QName-valued attributes
|
void |
setValidationParams(ValidationParams validationParams)
Set the validation parameters (as declared using saxon:param)
|
void |
setXSIType(SchemaType xsiType)
Set the value of the xsi:type attribute.
|
void |
startValidation(java.lang.String systemId) |
copy, copyTo, getConverter, getStringToDoubleConverter, isAllowYearZero, isDeclaredNotation, isValidURI, setAllowYearZero, setNotationSet, setStringToDoubleConverter, setTypeHierarchy, setURIChecker
public ValidationContext(ConversionRules rules)
public Controller getController()
public void setController(Controller controller)
controller
- the controller to be usedpublic InvalidityHandler getInvalidityHandler()
public void setInvalidityHandler(InvalidityHandler invalidityHandler)
invalidityHandler
- the InvalidityHandler to be used for reporting validation failurespublic AssertionTreeBuilder getAssertionTreeBuilder()
public void setAssertionTreeBuilder(AssertionTreeBuilder assertionTreeBuilder)
public void startValidation(java.lang.String systemId)
public Sequence<?> getValidationErrorObject()
public ValidationParams getValidationParams()
public boolean hasValidationParams()
public void setValidationParams(ValidationParams validationParams)
validationParams
- the validation parameter values. May be null if none are required.public void setConstraintChecker(ConstraintChecker checker)
checker
- the constraint checkerprotected ConstraintChecker getConstraintChecker()
public void setStartTagBuffer(StartTagBufferEE startTag)
startTag
- the namespace resolverpublic StartTagBufferEE getStartTagBuffer()
public void setXSIType(SchemaType xsiType)
xsiType
- the schema type identified by the xsi:type attributepublic SchemaType getXSIType()
public void setErrorCode(java.lang.String errorCode)
errorCode
- the error codeprotected java.lang.String getErrorCode()
public void setErrorLimit(int limit)
limit
- the limit on the number of errorspublic boolean incrementErrorCount(ValidationFailure failure)
failure
- the invalidity that was foundpublic ValidationFailure getFirstFailure()
public int getErrorCount()
public Location getInitiatingLocation()
public void setInitiatingLocation(Location initiatingLocation)
Copyright (c) 2004-2020 Saxonica Limited. All rights reserved.