Should nested classes in an Enum be Enum members?

Ian Kelly ian.g.kelly at gmail.com
Fri Jun 29 03:17:02 EDT 2018


On Thu, Jun 28, 2018 at 7:01 PM Ben Finney <ben+python at benfinney.id.au> wrote:
>
> Ian Kelly <ian.g.kelly at gmail.com> writes:
>
> > On Thu, Jun 28, 2018 at 4:38 AM Ben Finney <ben+python at benfinney.id.au> wrote:
> > >
> > > Ethan Furman <ethan at stoneleaf.us> writes:
> > >
> > > Specifically, I can't make sense of why someone would want to have a
> > > class that is simultaneously behaving as an enumerated type, *and*
> > > has an API of custom callable attributes.
> >
> > You don't see value in enum members having properties?
>
> Is a Python property a callable attribute?

I was referring to properties generically in the OOP sense, not to
Python properties specifically.



More information about the Python-list mailing list