public class RegistrationVisitor extends ModelVisitor
ValidationContext
class to handle registration of
items which can be referenced by name or by function (such as ID values
within an object structure). The only items of this type which are not
handled by this visitor are format definitions. The formats need to be
accessed during prevalidation, so they're registered during that pass.Modifier and Type | Field and Description |
---|---|
private ValidationContext |
m_context
Validation context running this visitor.
|
Constructor and Description |
---|
RegistrationVisitor(ValidationContext vctx)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
visit(ContainerElementBase node)
Visit container element.
|
boolean |
visit(MappingElementBase node)
Visit mapping element.
|
boolean |
visit(TemplateElementBase node)
Visit template element.
|
void |
visitTree(ElementBase root)
Visit binding model tree to handle registration.
|
private final ValidationContext m_context
public RegistrationVisitor(ValidationContext vctx)
vctx
- validation context that will run this visitorpublic void visitTree(ElementBase root)
root
- node of tree to be visitedpublic boolean visit(ContainerElementBase node)
ModelVisitor
visit
in class ModelVisitor
node
- container element being visitedtrue
if children to be processed, false
if notpublic boolean visit(TemplateElementBase node)
ModelVisitor
visit
in class ModelVisitor
node
- template element being visitedtrue
if children to be processed, false
if notpublic boolean visit(MappingElementBase node)
ModelVisitor
visit
in class ModelVisitor
node
- mapping element being visitedtrue
if children to be processed, false
if not