|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.saxon.event.SerializerFactory
Helper class to construct a serialization pipeline for a given result destination and a given set of output properties. The pipeline is represented by a Receiver object to which result tree events are sent. Since Saxon 8.8 is is possible to write a subclass of SerializerFactory and register it with the Configuration, allowing customisation of the Serializer pipeline. The class includes methods for instantiating each of the components used on the Serialization pipeline. This allows a customized SerializerFactory to replace any or all of these components by subclasses that refine the behaviour.
Constructor Summary | |
SerializerFactory()
|
Method Summary | |
protected Receiver |
createHTMLSerializer(Emitter emitter,
java.util.Properties props,
PipelineConfiguration pipe,
CharacterMapExpander characterMapExpander,
ProxyReceiver normalizer)
|
protected Receiver |
createTextSerializer(Emitter emitter,
CharacterMapExpander characterMapExpander,
ProxyReceiver normalizer)
|
protected Receiver |
createXHTMLSerializer(Emitter emitter,
java.util.Properties props,
PipelineConfiguration pipe,
ProxyReceiver normalizer,
CharacterMapExpander characterMapExpander)
|
protected Receiver |
createXMLSerializer(Emitter emitter,
java.util.Properties props,
PipelineConfiguration pipe,
ProxyReceiver normalizer,
CharacterMapExpander characterMapExpander)
|
Receiver |
getReceiver(javax.xml.transform.Result result,
PipelineConfiguration pipe,
java.util.Properties props)
Get a Receiver that wraps a given Result object. |
protected ProxyReceiver |
newCDATAFilter(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new CDATA Filter, responsible for insertion of CDATA sections where required |
CharacterMapExpander |
newCharacterMapExpander()
Create a new CharacterMapExpander |
protected ContentHandlerProxy |
newContentHandlerProxy()
Create a ContentHandlerProxy |
protected Emitter |
newHTMLEmitter()
Create a new HTML Emitter |
protected ProxyReceiver |
newHTMLIndenter(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new HTML Indenter |
protected MetaTagAdjuster |
newHTMLMetaTagAdjuster(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new XHTML MetaTagAdjuster, responsible for insertion, removal, or replacement of meta elements |
protected ProxyReceiver |
newHTMLURIEscaper(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new HTML URI Escaper, responsible for percent-encoding of URIs in HTML output documents |
protected Emitter |
newTEXTEmitter()
Create a new Text Emitter |
protected UncommittedSerializer |
newUncommittedSerializer(javax.xml.transform.Result result,
java.util.Properties properties)
Create an UncommittedSerializer |
protected ProxyReceiver |
newUnicodeNormalizer(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a Unicode Normalizer |
protected Emitter |
newXHTMLEmitter()
Create a new XHTML Emitter |
protected ProxyReceiver |
newXHTMLIndenter(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new XHTML Indenter |
protected MetaTagAdjuster |
newXHTMLMetaTagAdjuster(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new XHTML MetaTagAdjuster, responsible for insertion, removal, or replacement of meta elements |
protected ProxyReceiver |
newXML10ContentChecker(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new XML 1.0 content checker, responsible for checking that the output conforms to XML 1.0 rules (this is used only if the Configuration supports XML 1.1 but the specific output file requires XML 1.0) |
protected Emitter |
newXMLEmitter()
Create a new XML Emitter |
protected ProxyReceiver |
newXMLIndenter(PipelineConfiguration pipe,
java.util.Properties outputProperties)
Create a new XML Indenter |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public SerializerFactory()
Method Detail |
public Receiver getReceiver(javax.xml.transform.Result result, PipelineConfiguration pipe, java.util.Properties props) throws XPathException
result
- The final destination of the serialized output. Usually a StreamResult,
but other kinds of Result are possible.pipe
- The PipelineConfiguration.props
- The serialization properties
XPathException
protected Receiver createHTMLSerializer(Emitter emitter, java.util.Properties props, PipelineConfiguration pipe, CharacterMapExpander characterMapExpander, ProxyReceiver normalizer) throws XPathException
XPathException
protected Receiver createTextSerializer(Emitter emitter, CharacterMapExpander characterMapExpander, ProxyReceiver normalizer)
protected Receiver createXHTMLSerializer(Emitter emitter, java.util.Properties props, PipelineConfiguration pipe, ProxyReceiver normalizer, CharacterMapExpander characterMapExpander) throws XPathException
XPathException
protected Receiver createXMLSerializer(Emitter emitter, java.util.Properties props, PipelineConfiguration pipe, ProxyReceiver normalizer, CharacterMapExpander characterMapExpander) throws XPathException
XPathException
protected ContentHandlerProxy newContentHandlerProxy()
protected UncommittedSerializer newUncommittedSerializer(javax.xml.transform.Result result, java.util.Properties properties)
protected Emitter newXMLEmitter()
protected Emitter newHTMLEmitter()
protected Emitter newXHTMLEmitter()
protected Emitter newTEXTEmitter()
protected ProxyReceiver newXMLIndenter(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected ProxyReceiver newHTMLIndenter(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected ProxyReceiver newXHTMLIndenter(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected MetaTagAdjuster newXHTMLMetaTagAdjuster(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected MetaTagAdjuster newHTMLMetaTagAdjuster(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected ProxyReceiver newHTMLURIEscaper(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected ProxyReceiver newCDATAFilter(PipelineConfiguration pipe, java.util.Properties outputProperties) throws XPathException
XPathException
protected ProxyReceiver newXML10ContentChecker(PipelineConfiguration pipe, java.util.Properties outputProperties)
protected ProxyReceiver newUnicodeNormalizer(PipelineConfiguration pipe, java.util.Properties outputProperties) throws XPathException
XPathException
public CharacterMapExpander newCharacterMapExpander()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |