|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.cocoon.xml.dom.DOMStreamer
public class DOMStreamer
The DOMStreamer
is a utility class that will generate SAX
events from a W3C DOM Document.
The DOMStreamer uses a different strategy based on the value of the normalizeNamespaces property:
DOMStreamer.NamespaceNormalizingDOMStreamer
.
Nested Class Summary | |
---|---|
static class |
DOMStreamer.DefaultDOMStreamer
The DefaultDOMStreamer is a utility class that will generate SAX
events from a W3C DOM Document. |
static class |
DOMStreamer.NamespaceNormalizingDOMStreamer
Streams a DOM tree to SAX events and normalizes namespace declarations on the way. |
Field Summary | |
---|---|
protected DOMStreamer.DefaultDOMStreamer |
defaultDOMStreamer
DOMStreamer used when namespace normalization should not explicitely happen. |
protected DOMStreamer.NamespaceNormalizingDOMStreamer |
namespaceNormalizingDOMStreamer
DOMStreamer used in case of namespace normalization. |
protected boolean |
normalizeNamespaces
Indicates whether namespace normalization should happen. |
Constructor Summary | |
---|---|
DOMStreamer()
Create a new DOMStreamer instance. |
|
DOMStreamer(ContentHandler content)
Create a new DOMStreamer instance. |
|
DOMStreamer(ContentHandler content,
LexicalHandler lexical)
Create a new DOMStreamer instance. |
|
DOMStreamer(XMLConsumer consumer)
Create a new DOMStreamer instance. |
Method Summary | |
---|---|
boolean |
isNormalizeNamespaces()
|
void |
recycle()
|
void |
setConsumer(XMLConsumer consumer)
Set the XMLConsumer that will receive XML data. |
void |
setContentHandler(ContentHandler handler)
Set the ContentHandler that will receive XML data. |
void |
setLexicalHandler(LexicalHandler handler)
Set the LexicalHandler that will receive XML data. |
void |
setNormalizeNamespaces(boolean normalizeNamespaces)
|
void |
stream(Node node)
Start the production of SAX events. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected boolean normalizeNamespaces
protected DOMStreamer.NamespaceNormalizingDOMStreamer namespaceNormalizingDOMStreamer
protected DOMStreamer.DefaultDOMStreamer defaultDOMStreamer
Constructor Detail |
---|
public DOMStreamer()
DOMStreamer
instance.
public DOMStreamer(ContentHandler content, LexicalHandler lexical)
DOMStreamer
instance.
public DOMStreamer(XMLConsumer consumer)
DOMStreamer
instance.
public DOMStreamer(ContentHandler content)
DOMStreamer
instance.
Method Detail |
---|
public void setConsumer(XMLConsumer consumer)
XMLConsumer
that will receive XML data.
setConsumer
in interface XMLProducer
public void setContentHandler(ContentHandler handler)
ContentHandler
that will receive XML data.
public void setLexicalHandler(LexicalHandler handler)
LexicalHandler
that will receive XML data.
public void stream(Node node) throws SAXException
SAXException
public boolean isNormalizeNamespaces()
public void setNormalizeNamespaces(boolean normalizeNamespaces)
public void recycle()
recycle
in interface Recyclable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |