DBF records API

Ethan Furman ethan at stoneleaf.us
Sat Jun 2 01:16:35 EDT 2012


Tim Chase wrote:
> On 06/01/12 19:05, Jon Clements wrote:
>> On 01/06/12 23:13, Tim Chase wrote:
>>> dbf.scatter_fields
>>>>>> *always* trump and refer to the method.
>> I did think about *trumping* one way or the other, but both *ugh*.
>> For the record, it sounded like the OP wanted to be able to use the
> dot-notation for accessing fields by name, and I think it's a pretty
> non-pythonic way to do it. I'd much rather just stick to purely
> using __getitem__ for the fields and attributes/methods for non-fields.

It can't be *that* non-Pythonic -- we now have namedtuples which pretty 
much behave just like my record class (although its indexes are only 
numbers, not strings as well).
~Ethan~


More information about the Python-list mailing list

AltStyle によって変換されたページ (->オリジナル) /