dbf.tables._DbfRecord

Package dbf :: Module tables :: Class _DbfRecord |
[hide private]

# Class _DbfRecord

source code

    object --+
             |
            _DbfRecord

Provides routines to extract and save data within the fields of a dbf record.

Instance Methods | [hide private]
_retrieveFieldValue(yo, record_data, fielddef) calls appropriate routine to fetch value stored in field from array | source code
_updateFieldValue(yo, fielddef, value) calls appropriate routine to convert value to ascii bytes, and save it in record | source code
_update_disk(yo, location=`'````'`, data=None) | source code
__call__(yo, *specs) | source code
__contains__(yo, key) | source code
__iter__(yo) | source code
__getattr__(yo, name) | source code
__getitem__(yo, item) | source code
__len__(yo) | source code
__setattr__(yo, name, value) x.__setattr__('name', value) <==> x.name = value | source code
__setitem__(yo, name, value) | source code
__str__(yo) str(x) | source code
__repr__(yo) repr(x) | source code
_createBlankRecord(yo) creates a blank record data chunk | source code
delete_record(yo) marks record as deleted | source code
gather_fields(yo, dictionary, drop=False) saves a dictionary into a record's fields keys with no matching field will raise a FieldMissing exception unless drop_missing = True | source code
read_record(yo) refresh record data from disk | source code
check_index(yo) | source code
reset_record(yo, keep_fields=None) blanks record | source code
scatter_fields(yo, blank=False) returns a dictionary of fieldnames and values which can be used with gather_fields(). | source code
undelete_record(yo) marks record as active | source code
write_record(yo, **kwargs) write record data to disk | source code
Inherited from `object`: `__delattr__`, `__getattribute__`, `__hash__`, `__init__`, `__reduce__`, `__reduce_ex__`

Static Methods | [hide private]
a new object with type S, a subtype of T |
__new__(cls, recnum, layout, kamikaze=`'````'`, _fromdisk=False) record = ascii array of entire record; layout=record specification; memo = memo object for table | source code

Class Variables | [hide private]
| field_names = `<dbf.tables.property object at 0x00EC79B0>`
| has_been_deleted = `<dbf.tables.property object at 0x00EC79F0>`
| record_number = `<dbf.tables.property object at 0x00EC7A10>`
| record_table = `<dbf.tables.property object at 0x00EC7A30>`

Properties | [hide private]
| _data
| _dirty
| _layout
| _recnum
Inherited from `object`: `__class__`

Method Details | [hide private]

### _retrieveFieldValue(yo, record_data, fielddef) | source code
calls appropriate routine to fetch value stored in field from array Parameters: `record_data` (array of characters) - the data portion of the record `fielddef` (dictionary with keys 'type', 'start', 'length', 'end', 'decimals', and 'flags') - description of the field definition Returns: python data stored in field

### __new__(cls, recnum, layout, kamikaze=`'````'`, _fromdisk=False) Static Method | source code
record = ascii array of entire record; layout=record specification; memo = memo object for table Returns: a new object with type S, a subtype of T Overrides: object.__new__

### __setattr__(yo, name, value) | source code
x.__setattr__('name', value) <==> x.name = value Overrides: object.__setattr__ (inherited documentation)

### __str__(yo) (Informal representation operator) | source code
str(x) Overrides: object.__str__ (inherited documentation)

### __repr__(yo) (Representation operator) | source code
repr(x) Overrides: object.__repr__ (inherited documentation)

### scatter_fields(yo, blank=False) | source code
returns a dictionary of fieldnames and values which can be used with gather_fields(). if blank is True, values are empty.