com.icl.saxon.expr

Class StyleSheetFunctionCall

public class StyleSheetFunctionCall extends Function

This class represents a call to a function defined in the stylesheet
Method Summary
Valueevaluate(Context c)
Evaluate the function
intgetDataType()
Determine the data type of the expression, if possible
intgetDependencies()
Determine which aspects of the context the expression depends on.
StringgetName()
Get the name of the function.
Expressionreduce(int dependencies, Context context)
Remove dependencies.
voidsetFunction(SAXONFunction f)
Create the reference to the saxon:function element
Expressionsimplify()
Simplify the function call

Method Detail

evaluate

public Value evaluate(Context c)
Evaluate the function

Parameters: context The context in which the function is to be evaluated

Returns: a Value representing the result of the function. This must be of the data type corresponding to the result of getType().

Throws: XPathException if the function cannot be evaluated.

getDataType

public int getDataType()
Determine the data type of the expression, if possible

Returns: Value.ANY (meaning not known in advance)

getDependencies

public int getDependencies()
Determine which aspects of the context the expression depends on. The result is a bitwise-or'ed value composed from constants such as Context.VARIABLES and Context.CURRENT_NODE

getName

public String getName()
Get the name of the function.

Returns: the name of the function, as used in XSL expressions, but excluding its namespace prefix

reduce

public Expression reduce(int dependencies, Context context)
Remove dependencies.

setFunction

public void setFunction(SAXONFunction f)
Create the reference to the saxon:function element

simplify

public Expression simplify()
Simplify the function call