com.ibm.xml.xapi

Interface XDynamicContext


  1. public interface XDynamicContext

Use the XDynamicContext to override execution-time settings. These are settings used when executing a prepared expression, query or stylesheet. See the XPathExecutable, XQueryExecutable, and XSLTExecutable execute methods that take an XDynamicContext as an argument. The XFactory class has the method newDynamicContext for creating new instances.

Execution time settings such as the values of external variables and resolvers for source, collections and results may be different for each call to the execute methods on an Executable.

Examples of execution-time settings:

Settings in XDynamicContext map to settings in the XPath, XQuery and XSLT dynamic context as defined in the specifications:
See Also:

Method Summary

Modifier and Type Method and Description
  1. void
bind(javax.xml.namespace.QName name,java.math.BigDecimal value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,java.math.BigInteger value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,boolean value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,byte value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,byte[] value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,double value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,javax.xml.datatype.Duration value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,float value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,int value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,long value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,org.w3c.dom.Node value)
Bind a value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,java.lang.Object value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,javax.xml.namespace.QName value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,short value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,javax.xml.transform.Source source)
Bind a Source object as a value for a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,java.lang.String value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,XItemView item)
Bind a single item value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bind(javax.xml.namespace.QName name,javax.xml.datatype.XMLGregorianCalendar value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindCollation(java.lang.String uri,java.text.Collator collator)
Associates the specified collation URI with the specified java.text.Collator.
  1. void
bindCollation(java.lang.String uri,java.util.Locale locale)
Associates the specified collation URI with the java.text.Collator for the specified java.util.Locale.
  1. void
bindFunction(javax.xml.namespace.QName qname,java.lang.reflect.Method method)
Bind a function to a name.
  1. void
bindFunction(javax.xml.namespace.QName qname,java.lang.reflect.Method method,java.lang.Object instanceObject)
Bind a function to a name.
  1. void
bindSequence(javax.xml.namespace.QName name,java.math.BigDecimal[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,java.math.BigInteger[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,boolean[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,byte[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT) depending on the type.
  1. void
bindSequence(javax.xml.namespace.QName name,byte[][] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,double[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,javax.xml.datatype.Duration[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,float[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,int[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,long[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,javax.xml.namespace.QName[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,short[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,java.lang.String[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,javax.xml.datatype.XMLGregorianCalendar[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. void
bindSequence(javax.xml.namespace.QName name,XSequenceCursor sequence)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT).
  1. java.lang.String
getBaseOutputURI()
Get the base output URI.
  1. java.text.Collator
getCollation(java.lang.String uri)
Get the Collator associated with the given collation URI.
  1. XCollectionResolver
getCollectionResolver()
Get the registered resolver for collections.
  1. boolean
getFeature(java.lang.String name)
Get the state of the named feature.
  1. javax.xml.datatype.Duration
getImplicitTimeZone()
Get the implicit time zone as a Duration object.
  1. XMessageHandler
getMessageHandler()
Get the dynamic message handler.
  1. XResultResolver
getResultResolver()
Get the registered resolver for result documents.
  1. XSourceResolver
getSourceResolver()
Get the registered resolver for source documents.
  1. XUnparsedTextResolver
getUnparsedTextResolver()
Get the registered resolver for unparsed text resources.
  1. javax.xml.namespace.QName
getXSLTInitialMode()
Get the name of the initial mode
  1. javax.xml.namespace.QName
getXSLTInitialTemplate()
Get the name of the initial template.
  1. void
removeBinding(javax.xml.namespace.QName qname)
Remove the binding for the specified variable.
  1. void
removeCollationBinding(java.lang.String uri)
Remove the Collator associated with the given collation URI.
  1. void
removeFunctionBinding(javax.xml.namespace.QName qname,int arity)
Remove the binding for the specified function.
  1. void
setBaseOutputURI(java.lang.String uri)
Sets the base URI to use when resolving result documents.
  1. void
setCollectionResolver(XCollectionResolver collectionResolver)
Registers a URI resolver for collections.
  1. void
setFeature(java.lang.String name,boolean value)
Set a feature for this dynamic context.
  1. void
setImplicitTimeZone(javax.xml.datatype.Duration implicitTimeZone)
Sets the implicit time zone.
  1. void
setMessageHandler(XMessageHandler handler)
Set a message handler to process dynamic errors and messages.
  1. void
setResultResolver(XResultResolver resultResolver)
Register a resolver for result documents.
  1. void
setSourceResolver(XSourceResolver sourceResolver)
Register a resolver for dynamically resolved source documents such as for the fn:doc function and the XSLT document function.
  1. void
setUnparsedTextResolver(XUnparsedTextResolver unparsedTextResolver)
Register a resolver for external resources loaded through the XSLT unparsed-text function.
  1. void
setXSLTInitialMode(javax.xml.namespace.QName initialMode)
Specify a mode to use as the initial mode in an XSLT transformation.
  1. void
setXSLTInitialTemplate(javax.xml.namespace.QName initialTemplate)
Specify a named template to use as the initial template in an XSLT transformation.

Method Detail

bind

  1. void bind(javax.xml.namespace.QName name,
  2. java.lang.Object value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. java.lang.String value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. java.lang.String[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. boolean value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. boolean[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. byte value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. byte[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT) depending on the type. The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name. Use this method for hexBinary or base64Binary types.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. byte[] value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name. Use this method for hexBinary or base64Binary types.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. byte[][] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name. Use this method for sequences of hexBinary or base64Binary.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. short value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. short[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. int value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. int[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. long value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. long[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. float value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. float[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. double value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. double[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. java.math.BigDecimal value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. java.math.BigDecimal[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. java.math.BigInteger value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. java.math.BigInteger[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. javax.xml.namespace.QName value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. javax.xml.namespace.QName[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. javax.xml.datatype.XMLGregorianCalendar value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. javax.xml.datatype.XMLGregorianCalendar[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. javax.xml.datatype.Duration value)
Bind an atomic value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. javax.xml.datatype.Duration[] values)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The values must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
values - The values for the sequence.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. org.w3c.dom.Node value)
Bind a value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
value - The value of the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. javax.xml.transform.Source source)
Bind a Source object as a value for a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.

The source will be parsed and bound as an XItemView (just as if XItemFactory.item(Source) was called and the result passed to bind(QName, XItemView)).

Parameters:
name - The name of the variable.
source - The Source object.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bind

  1. void bind(javax.xml.namespace.QName name,
  2. XItemView item)
Bind a single item value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
item - The item to bind to the variable.
Throws:
java.lang.NullPointerException - if name, or value is null.
See Also:

bindSequence

  1. void bindSequence(javax.xml.namespace.QName name,
  2. XSequenceCursor sequence)
Bind a sequence value to a variable (XPath, XQuery) or a param (XSLT). The value must be valid for the type that was specified in the static context (XPath), in the query (XQuery) or in the stylesheet (XSLT) for the same name.
Parameters:
name - The name of the variable.
sequence - The sequence to bind to the variable, may be null for an empty sequence.
Throws:
java.lang.NullPointerException - if name is null.
See Also:

removeBinding

  1. void removeBinding(javax.xml.namespace.QName qname)
Remove the binding for the specified variable.
Parameters:
qname - The name of the variable.
Throws:
java.lang.NullPointerException - if qname is null.

bindFunction

  1. void bindFunction(javax.xml.namespace.QName qname,
  2. java.lang.reflect.Method method)
Bind a function to a name. For static methods only. Use the version of bindFunction that takes the instance object as a parameter for instance methods.
Parameters:
qname - The name of the function.
method - The method.
Throws:
java.lang.NullPointerException - if qname, or method is null.
See Also:

bindFunction

  1. void bindFunction(javax.xml.namespace.QName qname,
  2. java.lang.reflect.Method method,
  3. java.lang.Object instanceObject)
Bind a function to a name. The method being bound must be an instance method. The instanceObject will be used as the object on which to call the method.
Parameters:
qname - The name of the function.
method - The method.
instanceObject - The object on which to call the method.
Throws:
java.lang.NullPointerException - if any of qname, method, or instanceObject is null.

removeFunctionBinding

  1. void removeFunctionBinding(javax.xml.namespace.QName qname,
  2. int arity)
Remove the binding for the specified function.
Parameters:
qname - The name of the function.
arity - The arity of the function. This is the number of parameters that the function takes. This function for example (removeFunction) takes 2 parameters so its arity is 2.
Throws:
java.lang.NullPointerException - if qname is null.
java.lang.IllegalArgumentException - if the arity

bindCollation

  1. void bindCollation(java.lang.String uri,
  2. java.util.Locale locale)
Associates the specified collation URI with the java.text.Collator for the specified java.util.Locale.

A NullPointerException is thrown if either argument is null. An IllegalArgumentException is thrown if uri is a relative URI reference or is the Unicode code point collation URI.

Calling this method is equivalent to calling bindCollation(uri, Collator.getInstance(locale))

With the exception of the Unicode code point collation URI, if a stylesheet, query or XPath expression performs an operation that requires a collation URI that has not been bound to a Collator in the XDynamicContext, the processor will throw an XProcessException.

Parameters:
uri - A collation URI
locale - The locale whose Collator will be associated with the specified collation URI
Throws:
java.lang.IllegalArgumentException - if the URI is not an absolute URI reference or is the Unicode code point collation URI
java.lang.NullPointerException - if either the URI or the locale is a null reference
See Also:

bindCollation

  1. void bindCollation(java.lang.String uri,
  2. java.text.Collator collator)
Associates the specified collation URI with the specified java.text.Collator.

A NullPointerException is thrown if either argument is null. An IllegalArgumentException is thrown if uri is a relative URI reference or is the Unicode code point collation URI.

With the exception of the Unicode code point collation URI, if a stylesheet, query or XPath expression performs an operation that requires a collation URI that has not been bound to a Collator in the XDynamicContext, the processor will throw an XProcessException.

Parameters:
uri - A collation URI
collator - The Collator that will be associated with the specified collation URI
Throws:
java.lang.IllegalArgumentException - if the URI is not an absolute URI reference or is the Unicode code point collation URI
java.lang.NullPointerException - if either the URI or the locale is a null reference
See Also:

getCollation

  1. java.text.Collator getCollation( java.lang.String uri)
Get the Collator associated with the given collation URI.
Parameters:
uri - The collation URI.
Returns:
The associated Collator or null if no collator has been bound to this the given URI.
Throws:
java.lang.NullPointerException - if uri is null.

removeCollationBinding

  1. void removeCollationBinding(java.lang.String uri)
Remove the Collator associated with the given collation URI.
Parameters:
uri - The collation URI.
Throws:
java.lang.NullPointerException - if uri is null.

getImplicitTimeZone

  1. javax.xml.datatype.Duration getImplicitTimeZone( )
Get the implicit time zone as a Duration object.
Returns:
The implicit time zone or null if not set.

setImplicitTimeZone

  1. void setImplicitTimeZone(javax.xml.datatype.Duration implicitTimeZone)
Sets the implicit time zone. Pass in null for the implicitTimeZone to restore the default.
Parameters:
implicitTimeZone - Time zone to be set as a Duration object or null.

setBaseOutputURI

  1. void setBaseOutputURI(java.lang.String uri)

Sets the base URI to use when resolving result documents. Pass in null for the uri to restore the default. The default is either the base URI for the primary result document if one is passed into the execute method or the current working directory.

This setting is XSLT specific.

Parameters:
uri - The base output URI or null.

getBaseOutputURI

  1. java.lang.String getBaseOutputURI( )
Get the base output URI.
Returns:
The base output URI or null if not set.

setMessageHandler

  1. void setMessageHandler(XMessageHandler handler)
Set a message handler to process dynamic errors and messages. Pass in null for the handler to restore the default message handling behaviour. The default is to print messages to System.err and to also throw an XProcessException for fatal errors.
Parameters:
handler - The error handler or null.
See Also:

getMessageHandler

  1. XMessageHandler getMessageHandler( )
Get the dynamic message handler.
Returns:
The message handler or null if not set.

getSourceResolver

  1. XSourceResolver getSourceResolver( )
Get the registered resolver for source documents.
Returns:
The registered resolver or null if there is none.

setSourceResolver

  1. void setSourceResolver(XSourceResolver sourceResolver)
Register a resolver for dynamically resolved source documents such as for the fn:doc function and the XSLT document function. This source resolver has no effect on documents that are resolved statically such as XSLT imports and includes. For these documents the XStaticContext.setSourceResolver method should be used. Pass in null for the sourceResolver to restore the default source lookup behaviour. The default source resolution behavior is to interpret relative URIs in terms of the base URI from the static context if available or to interpret them as file: paths relative to the current working directory if the base URI is not available. Absolute URIs are used unchanged.
Parameters:
sourceResolver - The source document resolver or null.
See Also:

getResultResolver

  1. XResultResolver getResultResolver( )
Get the registered resolver for result documents.
Returns:
The registered resolver or null if there is none.

setResultResolver

  1. void setResultResolver(XResultResolver resultResolver)

Register a resolver for result documents. The resolver will be invoked when the xsl:result-document instruction is used in a XSLT stylesheet. Pass in null for resultResolver to restore the default result resolution behaviour. The default behavior is to use the base output URI to resolve result documents.

This setting is XSLT specific.

Parameters:
resultResolver - The result document resolver or null.
See Also:

setFeature

  1. void setFeature(java.lang.String name,
  2. boolean value)

Set a feature for this dynamic context.

Feature names should be fully qualified java.net.URIs. Implementations may define their own features.

Note: there are no currently defined features, this is for future use.

Parameters:
name - Feature name.
value - Is feature state true or false.
Throws:
java.lang.NullPointerException - if name is null.

getFeature

  1. boolean getFeature(java.lang.String name)

Get the state of the named feature.

Feature names should be fully qualified java.net.URIs. Implementations may define their own features.

Note: there are no currently defined features, this is for future use.

Parameters:
name - Feature name.
Returns:
State of the named feature.
Throws:
java.lang.NullPointerException - if name is null.

setXSLTInitialTemplate

  1. void setXSLTInitialTemplate(javax.xml.namespace.QName initialTemplate)

Specify a named template to use as the initial template in an XSLT transformation.

If a named template is not set, the initial template is determined by the initial mode, context node, and template matching rules

This setting is XSLT specific.

Parameters:
initialTemplate - The name of the template to use as the initial template, or null to allow the initial template to be determined by the template matching rules.

getXSLTInitialTemplate

  1. javax.xml.namespace.QName getXSLTInitialTemplate( )
Get the name of the initial template.
Returns:
The name of the initial template, or null if not set.

setXSLTInitialMode

  1. void setXSLTInitialMode(javax.xml.namespace.QName initialMode)

Specify a mode to use as the initial mode in an XSLT transformation.

This setting is XSLT specific.

Parameters:
initialMode - The name of the initial mode, or null for the default mode.

getXSLTInitialMode

  1. javax.xml.namespace.QName getXSLTInitialMode( )
Get the name of the initial mode
Returns:
The name of the initial mode, or null if not set.

getCollectionResolver

  1. XCollectionResolver getCollectionResolver( )
Get the registered resolver for collections.
Returns:
The XCollectionResolver if set, otherwise null.

setCollectionResolver

  1. void setCollectionResolver(XCollectionResolver collectionResolver)
Registers a URI resolver for collections. Pass in null for the collectionResolver to remove it. If no collection resolver is registered then calls to fn:collection will result in a recoverable error and the empty sequence is used for the collection.
Parameters:
collectionResolver - The collection resolver or null.
See Also:

setUnparsedTextResolver

  1. void setUnparsedTextResolver(XUnparsedTextResolver unparsedTextResolver)
Register a resolver for external resources loaded through the XSLT unparsed-text function. Pass in null for the unparsedTextResolver to restore the default unparsed text lookup behaviour. The default unparsed text resolution behaviour is to interpret relative URIs in terms of the base URI from the static context if available or to interpret them as file: paths relative to the current working directory if the base URI is not available. Absolute URIs are used unchanged.
Parameters:
unparsedTextResolver - The unparsed text resolver or null.
See Also:

getUnparsedTextResolver

  1. XUnparsedTextResolver getUnparsedTextResolver( )
Get the registered resolver for unparsed text resources.
Returns:
The registered resolver or null if there is none.