// The physical plan should contain the expression plan for this predecessor plus
// the subtree starting with this predecessor
for (int i=0; i<exps.size(); i++) {
currentPlan = new PhysicalPlan();
// translate the expression plan
PlanWalker childWalker = new ReverseDependencyOrderWalker(exps.get(i));
pushWalker(childWalker);
childWalker.walk(new ExpToPhyTranslationVisitor(exps.get(i),
childWalker, gen, currentPlan, logToPhyMap ));
popWalker();
List<Operator> leaves = exps.get(i).getSinks();
for(Operator l: leaves) {
PhysicalOperator op = logToPhyMap.get(l);
if (l instanceof ProjectExpression ) {
int input = ((ProjectExpression)l).getInputNum();
// for each sink projection, get its input logical plan and translate it
Operator pred = preds.get(input);
childWalker = new SubtreeDependencyOrderWalker(inner, pred);
pushWalker(childWalker);
childWalker.walk(this);
popWalker();
// get the physical operator of the leaf of input logical plan
PhysicalOperator leaf = logToPhyMap.get(pred);