|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.biojava.utils.xml.XMLDispatcher
Simple implementation of XMLPeerFactory which delegates object- construction on the basis of tag name.
Constructor Summary | |
XMLDispatcher()
Construct a new XMLDispatcher which does not know about any tag names. |
Method Summary | |
java.lang.Object |
getXMLPeer(java.lang.String tag,
java.util.List children,
org.xml.sax.AttributeList al)
Return a Java object to reflect an XML element. |
void |
mapTag(java.lang.String tag,
XMLPeerFactory fact)
Add an XMLPeerFactory which constructs objects corresponding to a specific XML tag. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public XMLDispatcher()
Method Detail |
public void mapTag(java.lang.String tag, XMLPeerFactory fact)
tag
- the tag name to bind.fact
- an XMLPeerFactory implementation to invoke when
the specified tag is encountered.public java.lang.Object getXMLPeer(java.lang.String tag, java.util.List children, org.xml.sax.AttributeList al)
XMLPeerFactory
getXMLPeer
in interface XMLPeerFactory
tag
- the XML tag.children
- a List (may be empty) of objects reflecting
child nodes.al
- attribute list for the tag.
null
if
this element should be silently ignored.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |