Package com.icl.saxon.output
Class CDATAFilter
- java.lang.Object
-
- com.icl.saxon.output.Emitter
-
- com.icl.saxon.output.ProxyEmitter
-
- com.icl.saxon.output.CDATAFilter
-
- All Implemented Interfaces:
Result
public class CDATAFilter extends ProxyEmitter
CDATAFilter: This ProxyEmitter converts character data to CDATA sections, if the character data belongs to one of a set of element types to be handled this way.
-
-
Field Summary
-
Fields inherited from class com.icl.saxon.output.ProxyEmitter
baseEmitter, outputProperties
-
Fields inherited from class com.icl.saxon.output.Emitter
locator, namePool, outputStream, systemId, writer
-
Fields inherited from interface javax.xml.transform.Result
PI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING
-
-
Constructor Summary
Constructors Constructor Description CDATAFilter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcharacters(char[] chars, int start, int len)Output character datavoidcomment(char[] chars, int start, int len)Output a commentvoidendElement(int nameCode)Output element end tagvoidflush(StringBuffer buffer)Flush the buffer containing accumulated character data, generating it as CDATA where appropriatevoidignorableWhitespace(char[] chars, int start, int len)Output ignorable white spacebooleanisCDATA(int fingerprint)See if a particular element is a CDATA elementvoidprocessingInstruction(String target, String data)Output a processing instructionvoidsetEscaping(boolean escaping)Set escaping on or offvoidsetOutputProperties(Properties details)Set output propertiesvoidstartElement(int nameCode, Attributes atts, int[] namespaces, int nscount)Output element start tag-
Methods inherited from class com.icl.saxon.output.ProxyEmitter
endDocument, setDocumentLocator, setNamePool, setUnderlyingEmitter, setUnparsedEntity, setWriter, startDocument
-
Methods inherited from class com.icl.saxon.output.Emitter
getNamePool, getOutputProperties, getOutputStream, getSystemId, getWriter, makeEmitter, setOutputStream, setSystemId, usesWriter
-
-
-
-
Method Detail
-
startElement
public void startElement(int nameCode, Attributes atts, int[] namespaces, int nscount) throws TransformerExceptionOutput element start tag- Overrides:
startElementin classProxyEmitternamespaces- Array of namespace codes identifying the namespace prefix/uri pairs associated with this elementnscount- Number of significant entries within namespaces array- Throws:
TransformerException
-
endElement
public void endElement(int nameCode) throws TransformerExceptionOutput element end tag- Overrides:
endElementin classProxyEmitter- Throws:
TransformerException
-
processingInstruction
public void processingInstruction(String target, String data) throws TransformerException
Output a processing instruction- Overrides:
processingInstructionin classProxyEmitter- Throws:
TransformerException
-
characters
public void characters(char[] chars, int start, int len) throws TransformerExceptionOutput character data- Overrides:
charactersin classProxyEmitter- Throws:
TransformerException
-
ignorableWhitespace
public void ignorableWhitespace(char[] chars, int start, int len) throws TransformerExceptionOutput ignorable white space- Throws:
TransformerException
-
comment
public void comment(char[] chars, int start, int len) throws TransformerExceptionOutput a comment- Overrides:
commentin classProxyEmitter- Throws:
TransformerException
-
setEscaping
public void setEscaping(boolean escaping) throws TransformerExceptionSet escaping on or off- Overrides:
setEscapingin classProxyEmitter- Throws:
TransformerException
-
flush
public void flush(StringBuffer buffer) throws TransformerException
Flush the buffer containing accumulated character data, generating it as CDATA where appropriate- Throws:
TransformerException
-
setOutputProperties
public void setOutputProperties(Properties details)
Set output properties- Overrides:
setOutputPropertiesin classProxyEmitter
-
isCDATA
public boolean isCDATA(int fingerprint)
See if a particular element is a CDATA element
-
-