Corrections for jn:size 149/head
authorChristina Pavlopoulou <cpavl001@ucr.edu>
Sun, 21 Aug 2016 17:15:28 +0000 (10:15 -0700)
committerChristina Pavlopoulou <cpavl001@ucr.edu>
Sun, 21 Aug 2016 17:19:28 +0000 (10:19 -0700)
vxquery-core/src/main/java/org/apache/vxquery/functions/builtin-functions.xml
vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/misc/JnSizeScalarEvaluatorFactory.java [moved from vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/misc/FnSizeScalarEvaluatorFactory.java with 90% similarity]
vxquery-xtest/src/test/resources/Queries/XQuery/Json/Array/Navigation/q03_array_navigation.xq

index 9156331..10ca007 100644 (file)
         </property>
     </function>
 
-    <!-- fn:size($expr as  item()*) as xs:anyAtomicType* -->
-    <function name="fn:size">
+    <!-- jn:size($expr as  item()*) as xs:anyAtomicType* -->
+    <function name="jn:size">
         <param name="expr" type="item()*"/>
         <return type="xs:integer"/>
-        <runtime type="scalar" class="org.apache.vxquery.runtime.functions.misc.FnSizeScalarEvaluatorFactory"/>
+        <runtime type="scalar" class="org.apache.vxquery.runtime.functions.misc.JnSizeScalarEvaluatorFactory"/>
     </function>
 
     <!-- fn:dateTime($arg1  as xs:date?, $arg2 as xs:time?)  as xs:dateTime?  -->
@@ -33,25 +33,25 @@ import org.apache.vxquery.exceptions.SystemException;
 import org.apache.vxquery.runtime.functions.base.AbstractTaggedValueArgumentScalarEvaluator;
 import org.apache.vxquery.runtime.functions.base.AbstractTaggedValueArgumentScalarEvaluatorFactory;
 
-public class FnSizeScalarEvaluatorFactory extends AbstractTaggedValueArgumentScalarEvaluatorFactory {
+public class JnSizeScalarEvaluatorFactory extends AbstractTaggedValueArgumentScalarEvaluatorFactory {
 
     private static final long serialVersionUID = 1L;
 
-    public FnSizeScalarEvaluatorFactory(IScalarEvaluatorFactory[] args) {
+    public JnSizeScalarEvaluatorFactory(IScalarEvaluatorFactory[] args) {
         super(args);
     }
 
     @Override
     protected IScalarEvaluator createEvaluator(IHyracksTaskContext ctx, IScalarEvaluator[] args)
             throws AlgebricksException {
-        return new FnSizeScalarEvaluator(args);
+        return new JnSizeScalarEvaluator(args);
     }
 
-    private static class FnSizeScalarEvaluator extends AbstractTaggedValueArgumentScalarEvaluator {
+    private static class JnSizeScalarEvaluator extends AbstractTaggedValueArgumentScalarEvaluator {
         final ArrayBackedValueStorage abvs = new ArrayBackedValueStorage();
         final ArrayPointable ap = (ArrayPointable) ArrayPointable.FACTORY.createPointable();
 
-        public FnSizeScalarEvaluator(IScalarEvaluator[] args) {
+        public JnSizeScalarEvaluator(IScalarEvaluator[] args) {
             super(args);
         }