// <summary> // Copies a PhysicalProjectOp // </summary> public override Node Visit(PhysicalProjectOp op, Node n) { // Visit the Node's children and map their Vars var children = ProcessChildren(n); // Copy the ProjectOp's VarSet var newVarList = Copy(op.Outputs); var newColumnMap = Copy(op.ColumnMap) as SimpleCollectionColumnMap; Debug.Assert(newColumnMap != null, "Coping of a physical project's columnMap did not return a SimpleCollectionColumnMap"); // Create a new ProjectOp based on the copied VarSet var newProject = m_destCmd.CreatePhysicalProjectOp(newVarList, newColumnMap); // Return a new Node that references the copied ProjectOp and has the copied child Nodes as its children return(m_destCmd.CreateNode(newProject, children)); }