|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.saxon.functions.Extensions
This class implements functions that are supplied as standard with SAXON, but which are not defined in the XSLT or XPath specifications.
To invoke these functions, use a function call of the form prefix:name() where name is the method name, and prefix maps to a URI such as http://saxon.sf.net/net.sf.saxon.functions.Extensions (only the part of the URI after the last slash is important).
Method Summary | |
static SequenceIterator |
after(XPathContext context,
SequenceIterator ns1,
SequenceIterator ns2)
Find all the nodes in ns1 that are after the first node in ns2. |
static byte[] |
base64BinaryToOctets(Base64BinaryValue in)
Convert a base64Binary value to a sequence of integers representing the octets contained in the value |
static SecondsDurationValue |
dayTimeDurationFromSeconds(double arg)
Get a dayTimeDuration value corresponding to a given number of seconds |
static java.math.BigDecimal |
decimalDivide(java.math.BigDecimal arg1,
java.math.BigDecimal arg2,
int scale)
Perform decimal division to a user-specified precision |
static DocumentInfo |
discardDocument(XPathContext context,
DocumentInfo doc)
Remove a document from the document pool. |
static XPathContext |
getContext(XPathContext c)
Return the XPathContext object |
static java.lang.String |
getPseudoAttribute(XPathContext c,
java.lang.String name)
Get a pseudo-attribute of a processing instruction. |
static boolean |
hasSameNodes(SequenceIterator p1,
SequenceIterator p2)
Determine whether two node-sets contain the same nodes |
static byte[] |
hexBinaryToOctets(HexBinaryValue in)
Convert a hexBinary value to a sequence of integers representing the octets contained in the value |
static Value |
highest(SequenceIterator nsv)
Get the node with maximum numeric value of the string-value of each of a set of nodes |
static SequenceIterator |
highest(XPathContext context,
SequenceIterator nsv,
Evaluate.PreparedExpression pexpression)
Get the maximum numeric value of a stored expression over a set of nodes |
static SequenceIterator |
leading(XPathContext context,
SequenceIterator in,
Evaluate.PreparedExpression pexp)
Get the items that satisfy the given expression, up to and excluding the first one (in sequence order) that doesn't |
static int |
lineNumber(NodeInfo node)
Return the line number of the specified node. |
static int |
lineNumber(XPathContext c)
Return the line number of the context node. |
static Value |
lowest(SequenceIterator nsv)
Get the node with minimum numeric value of the string-value of each of a set of nodes |
static SequenceIterator |
lowest(XPathContext context,
SequenceIterator nsv,
Evaluate.PreparedExpression pexpression)
Get the node with minimum numeric value of a stored expression over a set of nodes |
static double |
max(XPathContext context,
SequenceIterator nsv,
Evaluate.PreparedExpression pexpression)
Get the maximum numeric value of a stored expression over a set of nodes |
static double |
min(XPathContext context,
SequenceIterator nsv,
Evaluate.PreparedExpression pexpression)
Get the minimum numeric value of a stored expression over a set of nodes |
static NodeInfo |
namespaceNode(XPathContext context,
java.lang.String prefix,
java.lang.String uri)
Create a parentless namespace node. |
static Base64BinaryValue |
octetsToBase64Binary(byte[] in)
Convert a sequence of integers in the range 0-255, representing a sequence of octets, to a base64Binary value |
static HexBinaryValue |
octetsToHexBinary(byte[] in)
Convert a sequence of integers in the range 0-255, representing a sequence of octets, to a hexBinary value |
static java.lang.String |
path(XPathContext c)
Return an XPath expression that identifies the current node |
static void |
pauseTracing(XPathContext c)
Switch tracing off. |
static void |
resumeTracing(XPathContext c)
Resume tracing. |
static java.util.List |
stringToUtf8(java.lang.String in)
Get the UTF-8 encoding of a string |
static double |
sum(XPathContext context,
SequenceIterator nsv,
Evaluate.PreparedExpression pexpression)
Total a stored expression over a set of nodes |
static java.lang.String |
systemId(XPathContext c)
Return the system identifier of the context node |
static SequenceIterator |
tokenize(java.lang.String s)
Return a node-set by tokenizing a supplied string. |
static SequenceIterator |
tokenize(java.lang.String s,
java.lang.String delim)
Return a sequence by tokenizing a supplied string. |
static java.lang.String |
typeAnnotation(XPathContext context,
NodeInfo node)
Display the value of the type annotation of a node |
static MonthDurationValue |
yearMonthDurationFromMonths(double arg)
Get a yearMonthDuration value corresponding to a given number of months |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static void pauseTracing(XPathContext c)
public static void resumeTracing(XPathContext c)
public static java.lang.String systemId(XPathContext c) throws XPathException
XPathException
public static int lineNumber(XPathContext c)
public static int lineNumber(NodeInfo node)
public static DocumentInfo discardDocument(XPathContext context, DocumentInfo doc)
context
- the evaluation context (supplied implicitly by the call mechanism)doc
- the document to be released from the document pool
public static boolean hasSameNodes(SequenceIterator p1, SequenceIterator p2) throws XPathException
p1
- The first node-set. The iterator must be correctly ordered.p2
- The second node-set. The iterator must be correctly ordered.
XPathException
public static double sum(XPathContext context, SequenceIterator nsv, Evaluate.PreparedExpression pexpression) throws XPathException
XPathException
public static double max(XPathContext context, SequenceIterator nsv, Evaluate.PreparedExpression pexpression) throws XPathException
XPathException
public static double min(XPathContext context, SequenceIterator nsv, Evaluate.PreparedExpression pexpression) throws XPathException
XPathException
public static Value highest(SequenceIterator nsv) throws XPathException
XPathException
public static SequenceIterator highest(XPathContext context, SequenceIterator nsv, Evaluate.PreparedExpression pexpression) throws XPathException
XPathException
public static Value lowest(SequenceIterator nsv) throws XPathException
XPathException
public static SequenceIterator lowest(XPathContext context, SequenceIterator nsv, Evaluate.PreparedExpression pexpression) throws XPathException
XPathException
public static SequenceIterator leading(XPathContext context, SequenceIterator in, Evaluate.PreparedExpression pexp) throws XPathException
XPathException
public static SequenceIterator after(XPathContext context, SequenceIterator ns1, SequenceIterator ns2) throws XPathException
XPathException
public static SequenceIterator tokenize(java.lang.String s)
public static SequenceIterator tokenize(java.lang.String s, java.lang.String delim)
public static java.lang.String path(XPathContext c) throws XPathException
XPathException
public static java.lang.String typeAnnotation(XPathContext context, NodeInfo node)
public static XPathContext getContext(XPathContext c)
public static java.lang.String getPseudoAttribute(XPathContext c, java.lang.String name) throws XPathException
XPathException
public static SecondsDurationValue dayTimeDurationFromSeconds(double arg) throws XPathException
XPathException
public static MonthDurationValue yearMonthDurationFromMonths(double arg)
public static java.math.BigDecimal decimalDivide(java.math.BigDecimal arg1, java.math.BigDecimal arg2, int scale)
public static java.util.List stringToUtf8(java.lang.String in)
in
- the supplied string
public static Base64BinaryValue octetsToBase64Binary(byte[] in)
public static HexBinaryValue octetsToHexBinary(byte[] in)
public static byte[] base64BinaryToOctets(Base64BinaryValue in)
public static byte[] hexBinaryToOctets(HexBinaryValue in)
public static NodeInfo namespaceNode(XPathContext context, java.lang.String prefix, java.lang.String uri) throws XPathException
XPathException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |