On Oct 18, 2004, at 13:46, Josiah Carlson wrote: >> Attributes may be 'generic' (untyped) or 'typed', and are stored in >> the order they are declared in the class statement. The value provided >> in the definition above is the 'default value'. Simple attributes may >> also be provided, but won't be type checked or kept in the original >> order. To read the ini file, just do this: > > I think the syntax looks good, but as per a thread in python-list, you > cannot discover the order of class variables by any solution (metaclass > or otherwise), due to the fact that they become part of the class > dictionary; which is arbitrarily unordered. > > If ordering is important to a user, one could have an optional > __order__ > attribute that gives the list of items in-order. That's not quite true. TypedAttribute instances and iniSection's __new__ could have serial numbers. -bob
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4