Not fully OO ?
bruno.42.desthuilliers at websiteburo.invalid
Tue Sep 30 11:54:42 CEST 2008
Lawrence D'Oliveiro a écrit :
> In message <mailman.1515.1222382168.3487.python-list at python.org>, James
> Mills wrote:
>> On Fri, Sep 26, 2008 at 8:20 AM, Lawrence D'Oliveiro
>> <ldo at geek-central.gen.new_zealand> wrote:
>>> Object orientation IS procedural.
>> Correction: OOP is Imperative.
> No, "procedural".
Nope, "imperative" !-)
> The functional unit is called an "expression", the encapsulation of which is
> called a "function". Hence "functional".
> Similarly, the procedural unit is commonly called a "statement", the
> encapsulation of which is a "procedure", not an "imperator".
> Hence "procedural".
"imperative" means that the computation is done through statements that
modify the program's state.
"procedural" means that these statements are organized in "procedures",
that group a serie of statements.
OO is based on objects (that carry and manage internal state) and
messages. A message can happen to trigger a serie of statements that
modifies a program state, so you could say (and this wouldn't be totally
false) that an OO method can be seen as a procedure (or at least some
methods...), but the whole program's organization is still not the same
as one seen in procedural programming. IOW, it's more a matter of how
you design / organize your (otherwise imperative) program than anything
More information about the Python-list