/** * Fully expands a RexLocalRef back into a pure RexNode tree containing no * RexLocalRefs (reversing the effect of common subexpression elimination). * For example, <code>program.expandLocalRef(program.getCondition())</code> * will return the expansion of a program's condition. * * @param ref a RexLocalRef from this program * @return expanded form */ public RexNode expandLocalRef(RexLocalRef ref) { return ref.accept(new ExpansionShuttle(exprs)); }
/** * Fully expands a RexLocalRef back into a pure RexNode tree containing no * RexLocalRefs (reversing the effect of common subexpression elimination). * For example, <code>program.expandLocalRef(program.getCondition())</code> * will return the expansion of a program's condition. * * @param ref a RexLocalRef from this program * @return expanded form */ public RexNode expandLocalRef(RexLocalRef ref) { return ref.accept(new ExpansionShuttle(exprs)); }
RexLocalRef ref = oldRef; if (updateRefs) { ref = (RexLocalRef) oldRef.accept(refShuttle); ref = (RexLocalRef) ref.accept(shuttle); this.projectRefList.add(ref); final String name = outFields.get(i).getName(); conditionRef = (RexLocalRef) conditionRef.accept(refShuttle); conditionRef = (RexLocalRef) conditionRef.accept(shuttle); addCondition(conditionRef);
RexLocalRef ref = oldRef; if (updateRefs) { ref = (RexLocalRef) oldRef.accept(refShuttle); ref = (RexLocalRef) ref.accept(shuttle); this.projectRefList.add(ref); final String name = outFields.get(i).getName(); conditionRef = (RexLocalRef) conditionRef.accept(refShuttle); conditionRef = (RexLocalRef) conditionRef.accept(shuttle); addCondition(conditionRef);