net.sf.saxon.style
Class XSLOutput
java.lang.Object
net.sf.saxon.tree.NodeImpl
net.sf.saxon.tree.ParentNodeImpl
net.sf.saxon.tree.ElementImpl
net.sf.saxon.style.StyleElement
net.sf.saxon.style.XSLOutput
- All Implemented Interfaces:
- java.io.Serializable, javax.xml.transform.Source, javax.xml.transform.SourceLocator, LocationProvider, SaxonLocator, PullEvent, Container, FingerprintedNode, Item, MutableNodeInfo, NamespaceResolver, NodeInfo, SiblingCountingNode, ValueRepresentation, InstructionInfo, org.xml.sax.Locator
public class XSLOutput
- extends StyleElement
An xsl:output element in the stylesheet.
- See Also:
- Serialized Form
Method Summary |
void |
checkAndPut(java.lang.String property,
java.lang.String value,
java.util.Properties props,
java.util.HashMap precedences)
Add an output property to the list of properties after checking that it is consistent
with other properties |
Expression |
compile(Executable exec)
Compile the instruction on the stylesheet tree into an executable instruction
for use at run-time. |
protected void |
gatherOutputProperties(java.util.Properties details,
java.util.HashMap precedences)
Validate the properties,
and return the values as additions to a supplied Properties object. |
StructuredQName |
getFormatQName()
Get the name of the xsl:output declaration |
void |
prepareAttributes()
Set the attribute list for the element. |
static java.lang.String |
prepareCharacterMaps(StyleElement element,
java.lang.String useCharacterMaps,
java.util.Properties details)
Process the use-character-maps attribute |
void |
validate()
Check that the stylesheet element is valid. |
Methods inherited from class net.sf.saxon.style.StyleElement |
allocateLocationId, allocatePatternSlots, allocateSlots, backwardsCompatibleModeIsEnabled, bindVariable, checkEmpty, checkSortComesFirst, checkTopLevel, checkUnknownAttribute, checkWithinTemplate, compileError, compileError, compileError, compileSequenceConstructor, compileWarning, definesExcludedNamespace, definesExtensionElement, fallbackProcessing, fixupReferences, forwardsCompatibleModeIsEnabled, getAllStylesheetFunctions, getAttributeSets, getAttributeValue, getColumnNumber, getCommonChildItemType, getConstructType, getContainingSlotManager, getContainingStylesheet, getDefaultCollationName, getDefaultXPathNamespace, getExecutable, getHostLanguage, getLastChildInstruction, getLineNumber, getLocationProvider, getNamespaceResolver, getObjectName, getPrecedence, getPreparedStylesheet, getPrincipalStylesheet, getProperties, getProperty, getReturnedItemType, getSchemaType, getStaticContext, getStylesheetFunction, getSystemId, getTypeAnnotation, getVersion, getWithParamInstructions, isExcludedNamespace, isExplaining, isExtensionNamespace, isInstruction, isPermittedChild, issueWarning, issueWarning, isTopLevel, makeAttributeValueTemplate, makeExpression, makeExpressionVisitor, makeNamespaceContext, makePattern, makeQName, makeSequenceType, makeSortKeys, makeTraceInstruction, markTailCalls, mayContainFallback, mayContainParam, mayContainSequenceConstructor, postValidate, processAllAttributes, processAttributes, processDefaultCollationAttribute, processDefaultXPathNamespaceAttribute, processExcludedNamespaces, processExtensionElementAttribute, processVersionAttribute, replaceSubExpression, reportAbsence, setObjectName, setValidationError, substituteFor, typeCheck, typeCheck, undeclaredNamespaceError, validateChildren, validateSubtree |
Methods inherited from class net.sf.saxon.tree.ElementImpl |
addNamespace, copy, delete, fixupInsertedNamespaces, generateId, getAttributeList, getAttributeValue, getAttributeValue, getBaseURI, getColumnNumber, getDeclaredNamespaces, getDocumentRoot, getInScopeNamespaceCodes, getLineNumber, getNameCode, getNodeKind, getPrefixForURI, getRoot, getSystemId, getTypeAnnotation, getURICodeForPrefix, getURICodeForPrefixCode, getURIForPrefix, initialise, isNilled, iteratePrefixes, putAttribute, removeAttribute, removeTypeAnnotation, rename, replaceStringValue, setLineAndColumn, setLocation, setNameCode, setNamespaceDeclarations, setSystemId, setTypeAnnotation |
Methods inherited from class net.sf.saxon.tree.ParentNodeImpl |
addChild, compact, enumerateChildren, getFirstChild, getLastChild, getNthChild, getNumberOfChildren, getSequenceNumber, getStringValue, getStringValueCS, hasChildNodes, insertChildren, insertChildrenAt, removeChild, replaceChildrenAt, useChildrenArray |
Methods inherited from class net.sf.saxon.tree.NodeImpl |
atomize, compareOrder, equals, getConfiguration, getDisplayName, getDocumentNumber, getFingerprint, getLocalPart, getNamePool, getNextInDocument, getNextSibling, getParent, getPhysicalRoot, getPrefix, getPreviousInDocument, getPreviousSibling, getPublicId, getSiblingPosition, getTypedValue, getURI, insertSiblings, isId, isIdref, isSameNodeInfo, iterateAxis, iterateAxis, newBuilder, replace |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.xml.sax.Locator |
getColumnNumber, getPublicId |
Methods inherited from interface javax.xml.transform.SourceLocator |
getColumnNumber, getPublicId |
XSLOutput
public XSLOutput()
prepareAttributes
public void prepareAttributes()
throws XPathException
- Description copied from class:
StyleElement
- Set the attribute list for the element. This is called to process the attributes (note
the distinction from processAttributes in the superclass).
Must be supplied in a subclass
- Specified by:
prepareAttributes
in class StyleElement
- Throws:
XPathException
getFormatQName
public StructuredQName getFormatQName()
- Get the name of the xsl:output declaration
- Returns:
- the name, as a structured QName; or null for an unnamed output declaration
validate
public void validate()
throws XPathException
- Description copied from class:
StyleElement
- Check that the stylesheet element is valid. This is called once for each element, after
the entire tree has been built. As well as validation, it can perform first-time
initialisation. The default implementation does nothing; it is normally overriden
in subclasses.
- Overrides:
validate
in class StyleElement
- Throws:
XPathException
compile
public Expression compile(Executable exec)
- Description copied from class:
StyleElement
- Compile the instruction on the stylesheet tree into an executable instruction
for use at run-time.
- Specified by:
compile
in class StyleElement
- Parameters:
exec
- the Executable
- Returns:
- either a ComputedExpression, or null. The value null is returned when compiling an instruction
that returns a no-op, or when compiling a top-level object such as an xsl:template that compiles
into something other than an instruction.
gatherOutputProperties
protected void gatherOutputProperties(java.util.Properties details,
java.util.HashMap precedences)
throws XPathException
- Validate the properties,
and return the values as additions to a supplied Properties object.
- Parameters:
details
- the Properties object to be populated with property valuesprecedences
- a HashMap to be populated with information about the precedence
of the property values: the key is the property name as a Clark name, the value
is a boxed integer giving the property's import precedence
- Throws:
XPathException
checkAndPut
public void checkAndPut(java.lang.String property,
java.lang.String value,
java.util.Properties props,
java.util.HashMap precedences)
throws XPathException
- Add an output property to the list of properties after checking that it is consistent
with other properties
- Parameters:
property
- the name of the propertyvalue
- the value of the ptopertyprops
- the list of properties to be updatedprecedences
- the import precedence of each property
- Throws:
XPathException
prepareCharacterMaps
public static java.lang.String prepareCharacterMaps(StyleElement element,
java.lang.String useCharacterMaps,
java.util.Properties details)
throws XPathException
- Process the use-character-maps attribute
- Parameters:
element
- the stylesheet element on which the use-character-maps attribute appearsuseCharacterMaps
- the value of the use-character-maps attributedetails
- The existing output properties
- Returns:
- the augmented value of the use-character-maps attribute in Clark notation
- Throws:
XPathException
- if the value is invalid