use of org.apache.commons.jxpath.ri.axes.NodeSetContext in project collect by openforis.
the class ModelExtensionFunction method computeValue.
@Override
public Object computeValue(EvalContext context) {
Object[] parameters = null;
if (args != null) {
parameters = new Object[args.length];
for (int i = 0; i < args.length; i++) {
Expression expression = args[i];
Iterator<?> computedValues = expression.iterate(context);
parameters[i] = convert(computedValues);
}
}
Object result = invoke(context, parameters);
return result instanceof NodeSet ? new NodeSetContext(context, (NodeSet) result) : result;
}
Aggregations