Package net.sf.saxon.event
Class XHTMLEmitter
- java.lang.Object
-
- net.sf.saxon.event.Emitter
-
- net.sf.saxon.event.XMLEmitter
-
- net.sf.saxon.event.XHTMLEmitter
-
- All Implemented Interfaces:
javax.xml.transform.Result,Receiver
public class XHTMLEmitter extends XMLEmitter
XHTMLEmitter is an Emitter that generates XHTML output. It is the same as XMLEmitter except that it follows the legacy HTML browser compatibility rules: for example, generating empty elements such as [BR /], and using [p][/p] for empty paragraphs rather than [p/]
-
-
Field Summary
Fields Modifier and Type Field Description (package private) IntHashSetemptyTagsTable of XHTML tags that have no closing tag-
Fields inherited from class net.sf.saxon.event.XMLEmitter
declarationIsWritten, elementCode, elementStack, empty, openStartTag, preferHex, specialInAtt, specialInText, undeclareNamespaces
-
Fields inherited from class net.sf.saxon.event.Emitter
allCharactersEncodable, characterSet, namePool, outputProperties, outputStream, pipelineConfig, streamResult, systemId, writer
-
-
Constructor Summary
Constructors Constructor Description XHTMLEmitter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.StringemptyElementTagCloser(java.lang.String displayName, int nameCode)Close an empty element tag.protected voidopenDocument()Do the real work of starting the document.-
Methods inherited from class net.sf.saxon.event.XMLEmitter
attribute, characters, close, closeStartTag, comment, endDocument, endElement, main, namespace, open, outputCharacterReference, processingInstruction, startContent, startDocument, startElement, testCharacters, writeAttribute, writeCharSequence, writeDeclaration, writeDocType, writeEscape
-
Methods inherited from class net.sf.saxon.event.Emitter
getConfiguration, getOutputProperties, getOutputStream, getPipelineConfiguration, getSystemId, getWriter, makeWriter, setOutputProperties, setOutputStream, setPipelineConfiguration, setStreamResult, setSystemId, setUnparsedEntity, setWriter, usesWriter
-
-
-
-
Field Detail
-
emptyTags
IntHashSet emptyTags
Table of XHTML tags that have no closing tag
-
-
Method Detail
-
openDocument
protected void openDocument() throws XPathExceptionDo the real work of starting the document. This happens when the first content is written.- Overrides:
openDocumentin classXMLEmitter- Throws:
XPathException
-
emptyElementTagCloser
protected java.lang.String emptyElementTagCloser(java.lang.String displayName, int nameCode)Close an empty element tag.- Overrides:
emptyElementTagCloserin classXMLEmitter
-
-