public class LastFunction extends Object implements Function
4.1 number last()
The last function returns a number equal to the context size from the expression evaluation context.
| Constructor and Description |
|---|
LastFunction()
Create a new
LastFunction object. |
| Modifier and Type | Method and Description |
|---|---|
Object |
call(Context context,
List args)
Returns the number of nodes in the context node-set.
|
static Double |
evaluate(Context context)
Returns the number of nodes in the context node-set.
|
public Object call(Context context, List args) throws FunctionCallException
call in interface Functioncontext - the context at the point in the
expression where the function is calledargs - an empty listDouble containing the context sizeFunctionCallException - if args is not emptyContext.getSize()public static Double evaluate(Context context)
context - the context at the point in the
expression where the function is calledContext.getSize()Copyright 2001–2022 The Jaxen Project. All rights reserved.