Class ChainedDigester
- java.lang.Object
-
- org.onemind.commons.java.xml.digest.DefaultDigester
-
- org.onemind.commons.java.xml.digest.AbstractElementCreatorDigester
-
- org.onemind.commons.java.xml.digest.ChainedDigester
-
- All Implemented Interfaces:
ElementCreatorDigester
,ElementDigester
public class ChainedDigester extends AbstractElementCreatorDigester
A ChainedDigester is a helper digester that chains the digestion of xml dynamically based on a dynamic digester configured as a attribute name.- Author:
- TiongHiang Lee (thlee@onemindsoft.org)
-
-
Constructor Summary
Constructors Constructor Description ChainedDigester(java.lang.String name)
ConstructorChainedDigester(java.lang.String name, java.lang.String attrName)
ConstructorChainedDigester(java.lang.String name, java.lang.String attrName, java.lang.Object[] args)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
startDigest(SaxDigesterHandler handler, org.xml.sax.Attributes attrs)
Start an element with the given attributes-
Methods inherited from class org.onemind.commons.java.xml.digest.AbstractElementCreatorDigester
addListener, endDigest, getCreatedElement, removeListener, setCreatedElement
-
Methods inherited from class org.onemind.commons.java.xml.digest.DefaultDigester
characters, getElementName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.onemind.commons.java.xml.digest.ElementDigester
characters, getElementName
-
-
-
-
Constructor Detail
-
ChainedDigester
public ChainedDigester(java.lang.String name)
Constructor- Parameters:
name
- the name of element
-
ChainedDigester
public ChainedDigester(java.lang.String name, java.lang.String attrName)
Constructor- Parameters:
name
- the element nameattrName
- the attr
-
ChainedDigester
public ChainedDigester(java.lang.String name, java.lang.String attrName, java.lang.Object[] args)
Constructor- Parameters:
name
- the element nameattrName
- the attribute the specifies the dynamic digesterargs
- arguments to pass to constructor of the dynamic digester
-
-
Method Detail
-
startDigest
public void startDigest(SaxDigesterHandler handler, org.xml.sax.Attributes attrs) throws org.xml.sax.SAXException
Start an element with the given attributes- Specified by:
startDigest
in interfaceElementDigester
- Overrides:
startDigest
in classDefaultDigester
- Parameters:
handler
- the handlerattrs
- the attributes- Throws:
org.xml.sax.SAXException
- if there's handling exception
-
-