public List<RelDataTypeField> getJoinFields(
          HiveLoptJoinTree left,
          HiveLoptJoinTree right) {
    RelDataType rowType =
            factory.createJoinType(
                    left.getJoinTree().getRowType(),
                    right.getJoinTree().getRowType());
    return rowType.getFieldList();
  }
Retrieves the fields corresponding to a join between a left and right
tree.

@param left left hand side of the join
@param right right hand side of the join

@return fields of the join
ql/src/java/org/apache/hadoop/hive/ql/optimizer/calcite/rules/HiveLoptMultiJoin.java