public class RootHandler extends java.lang.Object implements ArooaHandler
If the document tag is specified this will verify the name of the element root against the document tag.
The startHandler is provided as the handler for dealing with this document element. Thus the startHandler can then process the document element in it's onStartElement method as per the typical pattern of an ArooaHandler.
ArooaHandler
Constructor and Description |
---|
RootHandler(ArooaElement documentTag,
ElementAction<? extends org.oddjob.arooa.standard.InstanceRuntime> startHandler)
Constructor.
|
RootHandler(ElementAction<? extends org.oddjob.arooa.standard.InstanceRuntime> startHandler)
/**
Constructor.
|
Modifier and Type | Method and Description |
---|---|
ArooaContext |
onStartElement(ArooaElement element,
ArooaContext parentContext)
Handle the top level element.
|
public RootHandler(ElementAction<? extends org.oddjob.arooa.standard.InstanceRuntime> startHandler)
startHandler
- The handler to use for the top level element.public RootHandler(ArooaElement documentTag, ElementAction<? extends org.oddjob.arooa.standard.InstanceRuntime> startHandler)
documentTag
- The document tag which will be validated
against the top level element if not null.startHandler
- The handler to use for the top level element.public ArooaContext onStartElement(ArooaElement element, ArooaContext parentContext) throws ArooaConfigurationException
onStartElement
in interface ArooaHandler
element
- The configuration element.parentContext
- The parent ArooaContext.ArooaConfigurationException