Пример #1
0
 private static async Task FillDataAsync(IEnumerable <IColumn> columns, DataTable dataTable, Reader reader)
 {
     while (await reader.ReadAsync().ConfigureAwait(false))
     {
         dataTable.Rows.Add(LoadRow(dataTable, columns, reader));
     }
 }
Пример #2
0
        private static async Task <DataTable> FillDataAsync(IEnumerable <IColumn> columns, DataTable dataTable, Reader reader, CancellationToken cancellationToken = default(CancellationToken))
        {
            while (await reader.ReadAsync(cancellationToken).ConfigureAwait(false))
            {
                dataTable.Rows.Add(LoadRow(dataTable, columns, reader));
            }

            return(dataTable);
        }