public class ExpressionPresenter extends Object
Constructor and Description |
---|
ExpressionPresenter(Configuration config)
Make an ExpressionPresenter that writes indented output to the standard error output
destination of the Configuration
|
ExpressionPresenter(Configuration config,
Logger out)
Make an ExpressionPresenter that writes indented output to a specified output stream
|
ExpressionPresenter(Configuration config,
Receiver receiver)
Make an ExpressionPresenter for a given Configuration using a user-supplied Receiver
to accept the output
|
ExpressionPresenter(Configuration config,
StreamResult out)
Make an ExpressionPresenter that writes indented output to a specified output stream
|
ExpressionPresenter(Configuration config,
StreamResult out,
boolean checksum)
Make an ExpressionPresenter that writes indented output to a specified output stream,
with checksumming
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close the output
|
static Receiver |
defaultDestination(Configuration config,
Logger out)
Make a receiver, using default output properties, with serialized output going
to a specified OutputStream
|
void |
emitAttribute(String name,
String value)
Output an attribute node
|
void |
emitAttribute(String name,
StructuredQName value)
Output a QName-valued attribute node
|
void |
emitRetainedStaticContext(RetainedStaticContext sc) |
int |
endElement()
End an element in the expression tree
|
void |
endSubsidiaryElement()
End a child element in the output
|
Configuration |
getConfiguration()
Get the Saxon configuration
|
NamePool |
getNamePool()
Get the name pool
|
TypeHierarchy |
getTypeHierarchy()
Get the type hierarchy cache
|
static Properties |
makeDefaultProperties(Configuration config)
Make a Properties object containing defaulted serialization attributes for the expression tree
|
void |
namespace(String prefix,
String uri)
Output a namespace declaration
|
void |
setChildRole(String role)
Set the role of the next element to be output
|
void |
setDefaultNamespace(String namespace)
Set the default namespace, used for subsequent calls on startElement.
|
int |
startElement(String name)
Start an element
|
int |
startElement(String name,
Expression expr)
Start an element representing an expression in the expression tree
|
void |
startSubsidiaryElement(String name)
Start a child element in the output
|
public ExpressionPresenter(Configuration config)
config
- the Saxon configurationpublic ExpressionPresenter(Configuration config, StreamResult out)
config
- the Saxon configurationout
- the output destinationpublic ExpressionPresenter(Configuration config, StreamResult out, boolean checksum)
config
- the Saxon configurationout
- the output destinationpublic ExpressionPresenter(Configuration config, Logger out)
config
- the Saxon configurationout
- the output streampublic ExpressionPresenter(Configuration config, Receiver receiver)
config
- the Configurationreceiver
- the user-supplied Receiverpublic void setDefaultNamespace(String namespace)
namespace
- the default namespacepublic static Receiver defaultDestination(Configuration config, Logger out) throws XPathException
config
- the Configurationout
- the OutputStreamXPathException
public static Properties makeDefaultProperties(Configuration config)
public int startElement(String name, Expression expr)
name
- the name of the elementexpr
- the expression representedpublic void emitRetainedStaticContext(RetainedStaticContext sc)
public int startElement(String name)
name
- the name of the elementpublic void setChildRole(String role)
role
- the value of the role output to be usedpublic void emitAttribute(String name, String value)
name
- the name of the attributevalue
- the value of the attributepublic void emitAttribute(String name, StructuredQName value)
name
- the name of the attributevalue
- the value of the attributepublic void namespace(String prefix, String uri)
prefix
- the namespace prefixuri
- the namespace URIpublic int endElement()
public void startSubsidiaryElement(String name)
name
- the name of the child elementpublic void endSubsidiaryElement()
public void close()
public Configuration getConfiguration()
public NamePool getNamePool()
public TypeHierarchy getTypeHierarchy()
Copyright (c) 2004-2014 Saxonica Limited. All rights reserved.