private SelectResults evaluateAndJunction(ExecutionContext context)
      throws FunctionDomainException, TypeMismatchException, NameResolutionException,
      QueryInvocationTargetException {
    int len = abstractGroupOrRangeJunctions.size();
    // Asif : Create an array of SelectResults for each of the GroupJunction
    // For each Group Junction there will be a corresponding array of
    // RuntimeIterators which will map to the fields of the ResultSet obtained
    // from Group Junction.
    SelectResults[] results = new SelectResults[len];
    List finalList = context.getCurrentIterators();
    List expansionList = new LinkedList(finalList);
    RuntimeIterator[][] itrsForResultFields = new RuntimeIterator[len][];
    CompiledValue gj = null;
    Iterator junctionItr = abstractGroupOrRangeJunctions.iterator();
    List grpItrs = null;
    int j = 0;
    RuntimeIterator tempItr = null;
    while (junctionItr.hasNext()) {
      gj = (CompiledValue) junctionItr.next();
      SelectResults filterResults = ((Filter) gj).filterEvaluate(context, null);
      Support.Assert(filterResults != null, "FilterResults cannot be null here");
      if (filterResults.isEmpty()) {
        if (finalList.size() > 1) {
          StructType type = QueryUtils.createStructTypeForRuntimeIterators(finalList);
          return QueryUtils.createStructCollection(context, type);
        } else {
          ObjectType type = ((RuntimeIterator) finalList.iterator().next()).getElementType();
          if (type instanceof StructType) {
            return QueryUtils.createStructCollection(context, (StructTypeImpl) type);
          } else {
            return QueryUtils.createResultCollection(context, type);
          }
        }
      } else {
        results[j] = filterResults;
        grpItrs = (gj instanceof CompositeGroupJunction)
            ? QueryUtils.getDependentItrChainForIndpndntItrs(
                ((CompositeGroupJunction) gj).getIndependentIteratorsOfCJ(), context)
            : context.getCurrScopeDpndntItrsBasedOnSingleIndpndntItr(
                ((AbstractGroupOrRangeJunction) gj).getIndependentIteratorForGroup()[0]);
        itrsForResultFields[j] = new RuntimeIterator[grpItrs.size()];
        Iterator grpItr = grpItrs.iterator();
        int k = 0;
        while (grpItr.hasNext()) {
          tempItr = (RuntimeIterator) grpItr.next();
          itrsForResultFields[j][k++] = tempItr;
          expansionList.remove(tempItr);
        }
        ++j;
      }
    }
    SelectResults resultsSet = null;
    // Asif : Do the Cartesian of the different group junction results.
    CompiledValue iterOperandsToSend = null;
    if (!iterOperands.isEmpty()) {
      // TODO ASIF : Avoid creation of CompiledJunction by providing
      // functionality in AllGroupJunction for evaluating condition
      int size = iterOperands.size();
      CompiledValue[] cv = new CompiledValue[size];
      for (int k = 0; k < size; ++k) {
        cv[k] = (CompiledValue) iterOperands.get(k);
      }
      if (cv.length == 1) {
        iterOperandsToSend = cv[0];
      } else {
        iterOperandsToSend = new CompiledJunction(cv, operator);
      }
    }
    QueryObserver observer = QueryObserverHolder.getInstance();
    observer.beforeCartesianOfGroupJunctionsInAnAllGroupJunctionOfType_AND(results);
    resultsSet = QueryUtils.cartesian(results, itrsForResultFields, expansionList, finalList,
        context, iterOperandsToSend);
    observer.afterCartesianOfGroupJunctionsInAnAllGroupJunctionOfType_AND();
    Support.Assert(resultsSet != null, "ResultsSet obtained was NULL in AllGroupJunction");
    return resultsSet;
  }
Asif:Evaluates the individual GroupJunctions and CompositeGroupJunctions and does a cartesian
of the results so obtained and simultaneously expanding it to the query from clause level as
well as evaluating any iter evaluatable conditions. The evaluated result of an AllGroupJunction
will always be of the query from clause level which can be ORed or ANDd with filter evaluatable
subtree CompiledJunction

@param context ExecutionContext object
geode-core/src/main/java/org/apache/geode/cache/query/internal/AllGroupJunction.java