Class ReportDataTable
An in-memory table of rows with a fixed schema: the simplest way to hand a report its data.
public sealed class ReportDataTable
- Inheritance
-
ReportDataTable
- Inherited Members
Remarks
Values are checked against their column when a row is added, not when the report runs, so a mistake is reported where it was made. Value is stored as null.
A table is safe to read from several threads at once — each CreateReader() has its own position — once nobody is adding rows.
Constructors
Properties
- Columns
Gets the columns, in ordinal order.
- RowCount
Gets the number of rows.
Methods
- AddColumn(ReportDataColumn)
Adds a column. Columns must all be added before the first row.
- AddColumn(string, Type)
Adds a column that may hold null. Columns must all be added before the first row.
- AddRow(params object?[])
Adds a row.
- CreateReader()
Creates a reader over the rows, positioned before the first.