com.novell.xml.xpath.functions
Class xpathLast

java.lang.Object
  extended bycom.novell.xml.xpath.Function
      extended bycom.novell.xml.xpath.functions.xpathLast

public class xpathLast
extends Function

This class implements the XPath last() built-in function


Constructor Summary
xpathLast()
          Construct an object for the last() function
 
Method Summary
 ExpressionValue invoke(Object[] args)
          Perform last() function
 NumberValue last(Node contextNode, ExpressionContext context)
          Perform last() function
 String toString()
          Return function name.
 
Methods inherited from class com.novell.xml.xpath.Function
getInstance, getSignature, isConstant, registerForReset
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

xpathLast

public xpathLast()
Construct an object for the last() function

Method Detail

invoke

public ExpressionValue invoke(Object[] args)
                       throws XPathEvaluationException
Perform last() function

Overrides:
invoke in class Function
Parameters:
args - List of arguments. First first argument must be the context node. The second argument must be the expression context object
Returns:
A number indicating the number of nodes in the context node list
Throws:
XPathEvaluationException

last

public NumberValue last(Node contextNode,
                        ExpressionContext context)
                 throws XPathEvaluationException
Perform last() function

Parameters:
contextNode - expression context node
context - Context node list
Throws:
XPathEvaluationException

toString

public String toString()
Return function name.

Returns:
Function name.