コード例 #1
0
        // Create new table and add tuples to it
        public new static DataTableLocal Create(DataHeading heading, IEnumerable <ExpressionEval> texprs)
        {
            DataTableLocal newtable = DataTableLocal.Create(heading);

            foreach (var expr in texprs)
            {
                newtable.AddRow(expr.Evaluate().AsRow());
            }
            return(newtable);
        }
コード例 #2
0
        // Create new table as a copy (the other might be a different kind)
        public new static DataTableLocal Create(DataHeading heading, IEnumerable <DataRow> rows)
        {
            DataTableLocal newtable = DataTableLocal.Create(heading);

            foreach (var row in rows)
            {
                newtable.AddRow(row);
            }
            return(newtable);
        }