Order in metaclass

Nicolas Fleury nid_oizo at yahoo.com_remove_the_
Tue Oct 12 15:37:22 EDT 2004


In the following example:

class MyMetaclass(type): pass
class MyBaseType(object): __metaclass__ = MyMetaclass
class MyType(MyBaseType):
     x = 4
     y = 5
     z = 6

Is there any way to modify MyMetaclass to keep the order of x,y,z somewhere?

Thx and regards,
Nicolas



More information about the Python-list mailing list