/** * Returns the namespace URI of the specified node or the namespace URI of the context node if * no arguments are provided. * * @param context the context at the point in the * expression where the function is called * @param args a <code>List</code> containing zero or one items * * @return a <code>String</code> containing the namespace URI * * @throws FunctionCallException if <code>args</code> has more than one item */ public Object call(Context context, List args) throws FunctionCallException { if (args.size() == 0) { return evaluate( context.getNodeSet(), context.getNavigator() ); } if ( args.size() == 1 ) { return evaluate( args, context.getNavigator() ); } throw new FunctionCallException( "namespace-uri() requires zero or one argument." ); }
return evaluate( (List) first, nav );