Package com.icl.saxon.output
Class UncommittedEmitter
java.lang.Object
com.icl.saxon.output.Emitter
com.icl.saxon.output.ProxyEmitter
com.icl.saxon.output.UncommittedEmitter
- All Implemented Interfaces:
Result
This class generates XML or HTML output depending on whether the first tag output is ""
- Author:
- Michael H. Kay
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) boolean
(package private) boolean
(package private) boolean
(package private) StringBuffer
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 -
Method Summary
Modifier and TypeMethodDescriptionvoid
characters
(char[] ch, int start, int length) Produce character output using the current Writer.void
comment
(char[] ch, int start, int length) Output a commentvoid
End of documentvoid
processingInstruction
(String target, String data) Processing Instructionvoid
setEscaping
(boolean escaping) Switch escaping on or off.void
Start of documentvoid
startElement
(int nameCode, Attributes attributes, int[] namespaces, int nscount) Output an element start tag.Methods inherited from class com.icl.saxon.output.ProxyEmitter
endElement, setDocumentLocator, setNamePool, setOutputProperties, setUnderlyingEmitter, setUnparsedEntity, setWriter
Methods inherited from class com.icl.saxon.output.Emitter
getNamePool, getOutputProperties, getOutputStream, getSystemId, getWriter, makeEmitter, setOutputStream, setSystemId, usesWriter
-
Field Details
-
committed
boolean committed -
initialNewline
boolean initialNewline -
initialEscaping
boolean initialEscaping -
pendingCharacters
StringBuffer pendingCharacters
-
-
Constructor Details
-
UncommittedEmitter
public UncommittedEmitter()
-
-
Method Details
-
startDocument
Description copied from class:ProxyEmitter
Start of document- Overrides:
startDocument
in classProxyEmitter
- Throws:
TransformerException
-
endDocument
End of document- Overrides:
endDocument
in classProxyEmitter
- Throws:
TransformerException
-
characters
Produce character output using the current Writer.- Overrides:
characters
in classProxyEmitter
- Throws:
TransformerException
-
processingInstruction
Processing Instruction- Overrides:
processingInstruction
in classProxyEmitter
- Throws:
TransformerException
-
comment
Output a comment- Overrides:
comment
in classProxyEmitter
- Throws:
TransformerException
-
startElement
public void startElement(int nameCode, Attributes attributes, int[] namespaces, int nscount) throws TransformerException Output an element start tag.
This can only be called once: it switches to a substitute output generator for XML or HTML, depending on whether the tag is "HTML".- Overrides:
startElement
in classProxyEmitter
- Parameters:
namespaces
- Array of namespace codes identifying the namespace prefix/uri pairs associated with this elementnscount
- Number of significant entries within namespaces arrayname
- The element name (tag)- Throws:
TransformerException
-
setEscaping
Switch escaping on or off. This is called when the XSLT disable-output-escaping attribute is used to switch escaping on or off. It is not called for other sections of output (e.g. element names) where escaping is inappropriate.- Overrides:
setEscaping
in classProxyEmitter
- Throws:
TransformerException
-