fix intersect() to return a collection instead of an iterator (easier management of size() and other operations)
@@ -93,7 +93,11 @@ public class OSQLFunctionIntersect extends OSQLFunctionMultiValueAbstract<Object
}
}
- return iterator;
+ List result = new ArrayList();
+ while (iterator.hasNext()) {
+ result.add(iterator.next());
+ }
+ return result;
}
@Override
