Jeremy Bowers <[EMAIL PROTECTED]> wrote in message news:<[EMAIL PROTECTED]>... > On Thu, 10 Feb 2005 11:56:45 -0700, Steven Bethard wrote: > > > In the "empty classes as c structs?" thread, we've been talking in some > > detail about my proposed "generic objects" PEP. Based on a number of > > suggestions, I'm thinking more and more that instead of a single > > collections type, I should be proposing a new "namespaces" module instead. > > Context: I've never been excited by this proposal. > > But I am intrigued to note that with a couple of differences, you've now > converged on a module I've already written for my own use, which I called > a Registry. I actually subclassed 'dict', added some methods to use > dotted-access as you describe, and added some methods for accessing and > initializing a deeper key (basically a "get" that can handle hierarchy) > and a couple of other things. > > There are worse things for application config storing than a pickled > Namespace. (Not human readable, but if you don't care about that, as I > generally don't, it's close to usable.)
FWIW, you can count me about the people who (re)wrote this same thing (actually with some difference, since I wanted to keep the order, so I used nested lists instead of nested dictionaries, but the idea was similar). I would welcome some module in the standard library to store hierarchical data. Michele Simionato -- http://mail.python.org/mailman/listinfo/python-list