|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.xml.sax.helpers.DefaultHandler
org.openadaptor.util.sax.AbstractHierarchicalElementHandler
org.openadaptor.dmx.converter.DMXTagHandler
public abstract class DMXTagHandler
This class is the abstract superclass for all DMX element handlers.
It provides common behavior and initializes the link to the DMX handler factory.
It also gives a single access point to the class registry and standard exception raising for unknown or misplaced tags.
| Constructor Summary | |
|---|---|
DMXTagHandler()
|
|
| Method Summary | |
|---|---|
MOTypeRegistry |
getTypeRegistry()
Returns the class registry, where all known classes are stored. |
void |
handleSubResult(java.lang.String subTagName,
java.lang.Object resultObject)
This method throws an exception for any sub result. |
MOAttribute |
newAttribute()
Creates and returns a new empty attribute object. |
MOClass |
newClass()
Creates and returns a new empty class object. |
MOType |
newType(java.lang.String type)
Creates a new empty type object. |
protected long |
stringToInteger(java.lang.String aString)
Convert a given string to an integer. |
void |
tagViolationException(java.lang.String mainTag,
java.lang.String subTag)
Throws the exception for invalid tags iside onother tag. |
| Methods inherited from class org.openadaptor.util.sax.AbstractHierarchicalElementHandler |
|---|
activate, endElement, getController, getResult, reactivate, setController, startElement, tagName |
| Methods inherited from class org.xml.sax.helpers.DefaultHandler |
|---|
characters, endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.xml.sax.ContentHandler |
|---|
characters, endDocument, endPrefixMapping, ignorableWhitespace, processingInstruction, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping |
| Constructor Detail |
|---|
public DMXTagHandler()
| Method Detail |
|---|
public MOTypeRegistry getTypeRegistry()
MOTypeRegistry
public void tagViolationException(java.lang.String mainTag,
java.lang.String subTag)
throws DMXViolationException
mainTag - The tag of the tag handler, where the error occuredsubTag - The tag which is not valid inside the mainTag
DMXViolationException
public void handleSubResult(java.lang.String subTagName,
java.lang.Object resultObject)
throws DMXException
handleSubResult in class AbstractHierarchicalElementHandlersubTagName - The tag name of the sub elementresultObject - The result of the interpretation of the sub element
DMXViolationException - An element was found inside another element, where it is not valid.
DMXExceptionAbstractHierarchicalElementHandler.getResult()protected long stringToInteger(java.lang.String aString)
aString - The string representation of the integer value.
Long.parseLong(java.lang.String, int)public MOClass newClass()
public MOAttribute newAttribute()
public MOType newType(java.lang.String type)
type - The type of the new type ( atomic | alias | collection )
newClass()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||