private static RexNode shiftFilter(
      int start,
      int end,
      int offset,
      RexBuilder rexBuilder,
      List<RelDataTypeField> joinFields,
      int nTotalFields,
      List<RelDataTypeField> rightFields,
      RexNode filter) {
    int[] adjustments = new int[nTotalFields];
    for (int i = start; i < end; i++) {
      adjustments[i] = offset;
    }
    return filter.accept(
        new RexInputConverter(
            rexBuilder,
            joinFields,
            rightFields,
            adjustments));
  }
Classifies filters according to where they should be processed. They
either stay where they are, are pushed to the join (if they originated
from above the join), or are pushed to one of the children. Filters that
are pushed are added to list passed in as input parameters.

@param joinRel      join node
@param filters      filters to be classified
@param pushInto     whether filters can be pushed into the join
@param pushLeft     true if filters can be pushed to the left
@param pushRight    true if filters can be pushed to the right
@param joinFilters  list of filters to push to the join
@param leftFilters  list of filters to push to the left child
@param rightFilters list of filters to push to the right child
@return whether at least one filter was pushed
ql/src/java/org/apache/hadoop/hive/ql/optimizer/calcite/rules/HiveFilterJoinRule.java