com.virtualweaver.xotics.datamodel.xpath
Interface XpFunction

All Known Implementing Classes:
XpfAbstractFunction

public interface XpFunction

Interface XPath functions must implement. Generally, new functions should be created by deriving from com.virtualweaver.xotics.datamodel.xpath.function.

Version:
4.1

Method Summary
 XoDataType evaluate(XpContext ectx, XpEvaluable[] arguments)
          executes this function, with current XPath context and an array of arguments as XpEvaluable objects
 java.lang.String getLocalName()
          Returns the local name of the function
 java.lang.String getNameSpace()
          Returns the namespace of the function
 void setTokenPosition(int line, int col)
          This method is called by XPath engine to give positions of this in XPath request string.
 

Method Detail

getLocalName

public java.lang.String getLocalName()
Returns the local name of the function


getNameSpace

public java.lang.String getNameSpace()
Returns the namespace of the function


evaluate

public XoDataType evaluate(XpContext ectx,
                           XpEvaluable[] arguments)
                    throws XoException
executes this function, with current XPath context and an array of arguments as XpEvaluable objects

Parameters:
ectx - dynamic context
arguments - function arguments, not resolved
Returns:
an XPath compatible object resulting from computing
Throws:
XoException - in some error occurs during evaluation

setTokenPosition

public void setTokenPosition(int line,
                             int col)
This method is called by XPath engine to give positions of this in XPath request string.

Parameters:
line - line position of this function in XPath request
col - column position of this function in XPath request