Class XPathFunction
- java.lang.Object
-
- de.aristaflow.adept2.model.common.xml.XPathFunction
-
- All Implemented Interfaces:
net.sf.saxon.s9api.ExtensionFunction
public abstract class XPathFunction extends Object implements net.sf.saxon.s9api.ExtensionFunction
This class provides the basic means for a function used within XPath. Each function needs to have a unique name and will be called while evaluating XPath. It may have one or several input parameters and one return value or nothing.
-
-
Field Summary
Fields Modifier and Type Field Description protected net.sf.saxon.s9api.SequenceType[]
argType
The type of the input parameter of this function.protected net.sf.saxon.s9api.QName
name
The unique name of this function in XPath.protected net.sf.saxon.s9api.SequenceType
resType
The type of the return value of this function.
-
Constructor Summary
Constructors Constructor Description XPathFunction(net.sf.saxon.s9api.QName funcName, net.sf.saxon.s9api.ItemType paramType, net.sf.saxon.s9api.OccurrenceIndicator paramOcc)
Creates a new XPath function with the designated simple input and no return value.XPathFunction(net.sf.saxon.s9api.QName funcName, net.sf.saxon.s9api.ItemType resType, net.sf.saxon.s9api.OccurrenceIndicator resOcc, Pair<net.sf.saxon.s9api.ItemType,net.sf.saxon.s9api.OccurrenceIndicator>... params)
Creates a new XPath function with the designated return value and the designated input parameters.XPathFunction(net.sf.saxon.s9api.QName funcName, net.sf.saxon.s9api.ItemType paramType, net.sf.saxon.s9api.OccurrenceIndicator paramOcc, net.sf.saxon.s9api.ItemType resType, net.sf.saxon.s9api.OccurrenceIndicator resOcc)
Creates a new XPath function with the designated simple input parameter and the designated return value.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description net.sf.saxon.s9api.SequenceType[]
getArgumentTypes()
net.sf.saxon.s9api.QName
getName()
net.sf.saxon.s9api.SequenceType
getResultType()
-
-
-
Field Detail
-
name
protected final net.sf.saxon.s9api.QName name
The unique name of this function in XPath.
-
argType
protected final net.sf.saxon.s9api.SequenceType[] argType
The type of the input parameter of this function.
-
resType
protected final net.sf.saxon.s9api.SequenceType resType
The type of the return value of this function.
-
-
Constructor Detail
-
XPathFunction
public XPathFunction(net.sf.saxon.s9api.QName funcName, net.sf.saxon.s9api.ItemType paramType, net.sf.saxon.s9api.OccurrenceIndicator paramOcc)
Creates a new XPath function with the designated simple input and no return value.- Parameters:
funcName
- The unique name of this XPath function.paramType
- The type of the input parameter of this XPath function.paramOcc
- The occurrence of the input parameter of this XPath function. If this is more than 1, each occurrence will be a new input parameter.
-
XPathFunction
public XPathFunction(net.sf.saxon.s9api.QName funcName, net.sf.saxon.s9api.ItemType paramType, net.sf.saxon.s9api.OccurrenceIndicator paramOcc, net.sf.saxon.s9api.ItemType resType, net.sf.saxon.s9api.OccurrenceIndicator resOcc)
Creates a new XPath function with the designated simple input parameter and the designated return value.- Parameters:
funcName
- The unique name of this XPath function.paramType
- The type of the input parameter of this XPath function.paramOcc
- The occurrence of the input parameter of this XPath function. If this is more than 1, each occurrence will be a new input parameter.resType
- The type of the return value of this XPath function.resOcc
- The occurrence of the input parameter of this XPath function.
-
XPathFunction
@SafeVarargs public XPathFunction(net.sf.saxon.s9api.QName funcName, net.sf.saxon.s9api.ItemType resType, net.sf.saxon.s9api.OccurrenceIndicator resOcc, Pair<net.sf.saxon.s9api.ItemType,net.sf.saxon.s9api.OccurrenceIndicator>... params)
Creates a new XPath function with the designated return value and the designated input parameters.- Parameters:
funcName
- The unique name of this XPath function.resType
- The type of the return value of this XPath function ornull
for no return value.resOcc
- The occurrence of the input parameter of this XPath function.params
- The input parameters of this XPath function ornull
for no input parameters. If the occurrence of an input parameter is many, there will be several input parameters of this type at this position thus moving the positions of the following parameters.
-
-
Method Detail
-
getName
public net.sf.saxon.s9api.QName getName()
- Specified by:
getName
in interfacenet.sf.saxon.s9api.ExtensionFunction
-
getArgumentTypes
public net.sf.saxon.s9api.SequenceType[] getArgumentTypes()
- Specified by:
getArgumentTypes
in interfacenet.sf.saxon.s9api.ExtensionFunction
-
getResultType
public net.sf.saxon.s9api.SequenceType getResultType()
- Specified by:
getResultType
in interfacenet.sf.saxon.s9api.ExtensionFunction
-
-