// <summary> // Copies a group by into node // </summary> // <param name="op"> The Op to Copy </param> // <param name="n"> The Node that references the Op </param> // <returns> A copy of the original Node that references a copy of the original Op </returns> public override Node Visit(GroupByIntoOp op, Node n) { // Visit the Node's children and map their Vars var children = ProcessChildren(n); // Create a new GroupByOp that uses copies of the Key and Output VarSets of the original GroupByOp var newGroupOp = m_destCmd.CreateGroupByIntoOp(Copy(op.Keys), Copy(op.Inputs), Copy(op.Outputs)); // Return a new Node that references the copied GroupByOp and has the copied child Nodes as its children return(m_destCmd.CreateNode(newGroupOp, children)); }