Package com.ctc.wstx.dtd
Class DFAValidator
java.lang.Object
com.ctc.wstx.dtd.StructValidator
com.ctc.wstx.dtd.DFAValidator
Validator class that is based on a DFA constructed from DTD content
specification.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionMethod called when the end element of the scope this validator validates is encountered.Method that should be called to get the actual usable validator instance, from the 'template' validator.tryToValidate
(PrefixedName elemName) Method called when a new (start) element is encountered within the scope of parent element this validator monitors.
-
Field Details
-
mState
DFAState mStateFor root validator instance, the start state of DFA; for other instances, current state.
-
-
Constructor Details
-
DFAValidator
-
-
Method Details
-
newInstance
Description copied from class:StructValidator
Method that should be called to get the actual usable validator instance, from the 'template' validator.- Specified by:
newInstance
in classStructValidator
-
tryToValidate
Description copied from class:StructValidator
Method called when a new (start) element is encountered within the scope of parent element this validator monitors.- Specified by:
tryToValidate
in classStructValidator
- Returns:
- Null if element is valid in its current position; error message if not.
-
fullyValid
Description copied from class:StructValidator
Method called when the end element of the scope this validator validates is encountered. It should make sure that the content model is valid, and if not, to construct an error message.- Specified by:
fullyValid
in classStructValidator
- Returns:
- Null if the content model for the element is valid; error message if not.
-