Top Description Fields Constructors Methods
com.ctc.wstx.dtd

public final Class DFAValidator

extends StructValidator
Class Inheritance
Imports
java.util.*, com.ctc.wstx.util.PrefixedName, .StringUtil

Validator class that is based on a DFA constructed from DTD content specification.

Field Summary

Modifier and TypeField and Description
pack-priv DFAState
mState

For root validator instance, the start state of DFA; for other instances, current state.

Constructor Summary

AccessConstructor and Description
public
DFAValidator(DFAState initialState)

Method Summary

Modifier and TypeMethod and Description
public String
fullyValid()

Implements abstract com.ctc.wstx.dtd.StructValidator.fullyValid.

Method called when the end element of the scope this validator validates is encountered.

public StructValidator
newInstance()

Implements abstract com.ctc.wstx.dtd.StructValidator.newInstance.

Method that should be called to get the actual usable validator instance, from the 'template' validator.

public String
tryToValidate(PrefixedName elemName)

Implements abstract com.ctc.wstx.dtd.StructValidator.tryToValidate.

Method called when a new (start) element is encountered within the scope of parent element this validator monitors.

Field Detail

mStateback to summary
pack-priv DFAState mState

For root validator instance, the start state of DFA; for other instances, current state.

Constructor Detail

DFAValidatorback to summary
public DFAValidator(DFAState initialState)

Method Detail

fullyValidback to summary
public String fullyValid()

Implements abstract com.ctc.wstx.dtd.StructValidator.fullyValid.

Doc from com.ctc.wstx.dtd.StructValidator.fullyValid.

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.

Returns:String

Null if the content model for the element is valid; error message if not.

Annotations
@Override
newInstanceback to summary
public StructValidator newInstance()

Implements abstract com.ctc.wstx.dtd.StructValidator.newInstance.

Doc from com.ctc.wstx.dtd.StructValidator.newInstance.

Method that should be called to get the actual usable validator instance, from the 'template' validator.

Annotations
@Override
tryToValidateback to summary
public String tryToValidate(PrefixedName elemName)

Implements abstract com.ctc.wstx.dtd.StructValidator.tryToValidate.

Doc from com.ctc.wstx.dtd.StructValidator.tryToValidate.

Method called when a new (start) element is encountered within the scope of parent element this validator monitors.

Returns:String

Null if element is valid in its current position; error message if not.

Annotations
@Override