Package net.sf.saxon.serialize
Class AdaptiveEmitter
- java.lang.Object
-
- net.sf.saxon.event.SequenceReceiver
-
- net.sf.saxon.event.SequenceWriter
-
- net.sf.saxon.serialize.AdaptiveEmitter
-
- All Implemented Interfaces:
Result
,Receiver
,ReceiverWithOutputProperties
public class AdaptiveEmitter extends SequenceWriter implements ReceiverWithOutputProperties
This class implements the Adaptive serialization method defined in XSLT+XQuery Serialization 3.1.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) static ARegularExpression
QUOTES
-
Fields inherited from class net.sf.saxon.event.SequenceReceiver
pipelineConfiguration, previousAtomic, systemId
-
Fields inherited from interface javax.xml.transform.Result
PI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING
-
-
Constructor Summary
Constructors Constructor Description AdaptiveEmitter(PipelineConfiguration pipe, UnicodeWriter writer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Notify the end of the event streamProperties
getOutputProperties()
Get the serialization properties maintained by thisReceiver
void
setCharacterMap(CharacterMap map)
Set the CharacterMap to be used, if anyvoid
setMustClose(boolean mustClose)
Say whether the output must be closed on completionvoid
setNormalizationForm(Normalizer.Form normalizationForm)
Set the Unicode normalizer to be used for normalizing strings.void
setOutputProperties(Properties props)
void
write(Item item)
Abstract method to be supplied by subclasses: output one item in the sequence.-
Methods inherited from class net.sf.saxon.event.SequenceWriter
append, characters, comment, endDocument, endElement, getTreeModel, processingInstruction, setTreeModel, setUnparsedEntity, startDocument, startElement, usesTypeAnnotations
-
Methods inherited from class net.sf.saxon.event.SequenceReceiver
append, decompose, flatten, getConfiguration, getErrorCodeForDecomposingFunctionItems, getNamePool, getPipelineConfiguration, getSystemId, handlesAppend, open, setPipelineConfiguration, setSystemId
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.sf.saxon.event.Receiver
append, append, characters, comment, endDocument, endElement, getPipelineConfiguration, handlesAppend, open, processingInstruction, setPipelineConfiguration, setUnparsedEntity, startDocument, startElement, usesTypeAnnotations
-
Methods inherited from interface javax.xml.transform.Result
getSystemId, setSystemId
-
-
-
-
Field Detail
-
QUOTES
static ARegularExpression QUOTES
-
-
Constructor Detail
-
AdaptiveEmitter
public AdaptiveEmitter(PipelineConfiguration pipe, UnicodeWriter writer)
-
-
Method Detail
-
setMustClose
public void setMustClose(boolean mustClose)
Say whether the output must be closed on completion- Parameters:
mustClose
- true if the output must be closed
-
setOutputProperties
public void setOutputProperties(Properties props)
-
setNormalizationForm
public void setNormalizationForm(Normalizer.Form normalizationForm)
Set the Unicode normalizer to be used for normalizing strings.- Parameters:
normalizationForm
- the normalizationForm to be used
-
setCharacterMap
public void setCharacterMap(CharacterMap map)
Set the CharacterMap to be used, if any- Parameters:
map
- the character map
-
getOutputProperties
public Properties getOutputProperties()
Description copied from interface:ReceiverWithOutputProperties
Get the serialization properties maintained by thisReceiver
- Specified by:
getOutputProperties
in interfaceReceiverWithOutputProperties
- Returns:
- the serialization properties
-
write
public void write(Item item) throws XPathException
Abstract method to be supplied by subclasses: output one item in the sequence.- Specified by:
write
in classSequenceWriter
- Parameters:
item
- the item to be written to the sequence- Throws:
XPathException
- if any failure occurs while writing the item
-
close
public void close() throws XPathException
Description copied from interface:Receiver
Notify the end of the event stream- Specified by:
close
in interfaceReceiver
- Overrides:
close
in classSequenceWriter
- Throws:
XPathException
- if an error occurs
-
-