def append(self, record): """Append ``record`` to the database.""" record.index = self.header.recordCount record._write() self.header.recordCount += 1 self._changed = True self._new = False
def __setitem__(self, index, record): """Write `DbfRecord` instance to the stream.""" record.index = self._fixIndex(index) record._write() self._changed = True self._new = False