org.jaxen.function
public class LocalNameFunction extends Object implements Function
4.1 string local-name(node-set?)
The local-name function returns the local part of the expanded-name of the node in the argument node-set that is first in document order. If the argument node-set is empty or the first node has no expanded-name, an empty string is returned. If the argument is omitted, it defaults to a node-set with the context node as its only member.
See Also: Section 4.1 of the XPath Specification
| Constructor Summary | |
|---|---|
| LocalNameFunction()
Create a new LocalNameFunction object. | |
| Method Summary | |
|---|---|
| Object | call(Context context, List args)
Returns the local-name of the specified node or the context node if
no arguments are provided.
|
| static String | evaluate(List list, Navigator nav)
Returns the local-name of list.get(0)
|
LocalNameFunction object.Parameters: context the context at the point in the
expression where the function is called args a List containing zero or one items
Returns: a String containing the local-name
Throws: FunctionCallException if args has more than one item
list.get(0)
Parameters: list a list of nodes nav the Navigator used to retrieve the local name
Returns: the local-name of list.get(0)
Throws: FunctionCallException if list.get(0) is not a node