[Python-Dev] Enumeration items: type(EnumClass.item) is EnumClass
? (original) (raw)
Serhiy Storchaka storchaka at gmail.com
Mon Apr 29 21:15:38 CEST 2013
- Previous message: [Python-Dev] Enumeration items: `type(EnumClass.item) is EnumClass` ?
- Next message: [Python-Dev] Enumeration items: `type(EnumClass.item) is EnumClass` ?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
29.04.13 21:14, Glenn Linderman написав(ла):
1) Enum could be subclassed to provide different, sharable, types of behaviors, then further subclassed to provide a number of distinct sets of values with those behaviors.
You can use a multiclass inheritance for this.
2) Enum could be subclassed to provide one set of values, and then further subclassed to provide a number a distinct sets of behaviors for those sets of values.
How is it possible? You haven't any instance of subclass.
- Previous message: [Python-Dev] Enumeration items: `type(EnumClass.item) is EnumClass` ?
- Next message: [Python-Dev] Enumeration items: `type(EnumClass.item) is EnumClass` ?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]