internal OrderList ReplaceLast(OrderBase order) { Argument.NotNull(order, "order"); if (InternalNodes.Count == 0) { throw new InvalidOperationException("List is empty."); } var selectList = new OrderList(InternalNodes.SetItem(InternalNodes.Count - 1, order)); return(selectList); }
internal SelectList ReplaceLast(ProjectionBase projection) { Argument.NotNull(projection, "projection"); if (InternalNodes.Count == 0) { throw new InvalidOperationException("Couldn't do ReplaceLast for empty list."); } var selectList = new SelectList(InternalNodes.SetItem(InternalNodes.Count - 1, projection)); return(selectList); }
internal TableSourceList ReplaceLast(TableSourceBase tableSource) { Argument.NotNull(tableSource, "tableSource"); if (InternalNodes.Count == 0) { throw new InvalidOperationException("Couldn't do ReplaceLast for empty list."); } var selectList = new TableSourceList(InternalNodes.SetItem(InternalNodes.Count - 1, tableSource)); return(selectList); }