Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ FillLoadDataRowChunk()

int System.Data.Common.DataAdapter.FillLoadDataRowChunk ( SchemaMapping mapping,
int startRecord,
int maxRecords )
inlineprivateinherited

Definition at line 553 of file DataAdapter.cs.

554 {
555 DataReaderContainer dataReader = mapping.DataReader;
556 while (0 < startRecord)
557 {
558 if (!dataReader.Read())
559 {
560 return 0;
561 }
562 startRecord--;
563 }
564 int num = 0;
565 if (0 < maxRecords)
566 {
567 while (num < maxRecords && dataReader.Read())
568 {
570 {
571 try
572 {
573 mapping.LoadDataRowWithClear();
574 num++;
575 }
576 catch (Exception e) when (ADP.IsCatchableExceptionType(e))
577 {
578 ADP.TraceExceptionForCapture(e);
579 OnFillErrorHandler(e, mapping.DataTable, mapping.DataValues);
580 }
581 }
582 else
583 {
584 mapping.LoadDataRow();
585 num++;
586 }
587 }
588 }
589 else
590 {
591 num = FillLoadDataRow(mapping);
592 }
593 return num;
594 }
void OnFillErrorHandler(Exception e, DataTable dataTable, object[] dataValues)
int FillLoadDataRow(SchemaMapping mapping)

References System.Data.Common.DataAdapter._hasFillErrorHandler, System.Data.ProviderBase.SchemaMapping.DataReader, System.Data.ProviderBase.SchemaMapping.DataTable, System.Data.ProviderBase.SchemaMapping.DataValues, System.Data.Common.DataAdapter.FillLoadDataRow(), System.Data.Common.ADP.IsCatchableExceptionType(), System.Data.ProviderBase.SchemaMapping.LoadDataRow(), System.Data.ProviderBase.SchemaMapping.LoadDataRowWithClear(), System.Data.Common.DataAdapter.OnFillErrorHandler(), System.Data.ProviderBase.DataReaderContainer.Read(), and System.Data.Common.ADP.TraceExceptionForCapture().

Referenced by System.Data.Common.DataAdapter.FillFromReader().