Help With Better Design

apollonius2 at apollonius2 at
Thu Jun 21 22:41:23 CEST 2007

On Jun 21, 12:22 am, Bruno Desthuilliers <bruno.
42.desthuilli... at> wrote:
> apolloni... at a écrit :
> (snip)
> >>> I would like to be able to get a good hold of the concept
> >> state machines ?
> > Well both state machines and classes (objects).  That may be a bit of a
> > tall order to take on all at once but the concepts seem to be quite
> > related.
> They are, since OO was born from the use of state machines for
> simulation (the Simula language). But you can do state machines with a
> database and a procedural language too, and FWIW, the "state machine"
> aspect of OO is more often very informal and ad hoc.
> > I already have a great deal of material on Classes so good to
> > go there.
> Don't confuse "classes" with OO. The "OO" in OOP means
> "object-oriented", not class-oriented, and nothing in the most basics
> definitions of OO [1] requires nor even imply the notion of "class".
> This notion is mostly an artifact for easing the definition of a family
> of objects having similar implementation, and some 00 languages managed
> to get by without classes (look for "prototype-based languages" - the
> most known being javascript). wrt/ Python, classes are actually objects
> too, and instances have a reference to their class. Since one can
> dynamically modify the instance object -> class object relation at
> runtime, we're quite close to prototype-based languages !-)
> [1] "an object is defined by an identity, a state and a behaviour."

No, I realize classes are just a way to represent an object and are
simply a component of the given language. I started dabbling in
programming with C and then started playing with Python (I can see
where classes provide a great deal of power in python). I just want to
get to the point where I can sit down and work out a practical class,
then use it effectively. This discussion has given me a lot to work
with. Thanks!

More information about the Python-list mailing list