public bool Read() { do { row_ = dbfTable.GetRow(nextRecNo, false); // Don't throw an exception, returns null if record not found nextRecNo++; } while (skipDeleted && (row_ != null) && row_.deleted); return(row_ != null); }
private DbfRow GetRow(int dbfRecNo) { if (dbfRecNo < 1) { // '< 1' because recno rule as dbase/index rule _row = null; // don't found } else { _row = _dbfTable.GetRow(dbfRecNo - 1, false); } return(_row); }
public IEnumerator <T> GetEnumerator() { for (int i = firstRecNo; (i <= lastRecNo); i++) { DbfRow row = table.GetRow(i); if (this.skipDeleted && row.deleted) { continue; } yield return(row.Get <T>()); } }
private static void FillData(DbfTable table, DataTable dataTable) { for (int i = 0; i < table.recCount; i++) { var rowDT = dataTable.NewRow(); var recDBF = table.GetRow(i); foreach (var column in table.columns) { rowDT[column.name] = recDBF.GetValue(column) ?? DBNull.Value; } dataTable.Rows.Add(rowDT); } }
private bool MarchingOne(bool forward) { if (eof) { return(false); } // int direction = forward ? 1 : -1; do { _row = _dbfTable.GetRow(_row.recNo + direction, false); // Don't throw an exception, returns null if record not found } while (skipDeleted && (_row != null) && _row.deleted); return(_row != null); }