Re: Why is Object Oriented so successfull





S Perryman wrote:
topmind wrote:

S Perryman wrote:

DK>The question wether programming with ADTs or programming with sets of ADTs
DK>(polymorphism falls here) is essential to OOP is open. However moving up
DK>abstraction levels obviously requires the latter.

Type substitutability is what OOP (Simula) brought to the game (via
inheritance) . Type substitutability is a good means of implementing the
Open-Closed Principle, solving all the grief of the "variant record"
problem (coupling etc) .

What "variant record problem"?

I've asked for this in the past

The "issue" of :

1. having a set of related entities, all/some having the same
properties, and each having properties specific to itself. Users of
the entities may wish to reference instances of the set as an entity
that has properties in common, or as the specific entity type.

2. changing the properties of any member of the
set, without affecting/impacting the other members (interface, impl) .

3. changing the representations (impls) of any member of the
set, without affecting/impacting the other members (interface, impl) .

4. changing the code written by users of the entity set, whenever the
members of the set changes.

5. correctness (being able to confirm the attempted use of properties
that do or do not belong to members of the set) .


All of these issues are known to experienced developers having faced
the variant record problem.

Similarly, said developers know that various programming paradigms/
langs can solve some of the problems, but not all. Type substitutability
(when used with other constructs/techniques) allows all of them to be
resolved.


> but nobody shown a practical example

Strange. Because "practical examples" are so easy to define.
And a basic example exists in a book you have so often claimed to debunk.

Then it should be easy for you to bring one up without fuss or muss.


If you understand or have experienced the variant record problem, you
should be able to define your own example in moments.

Not if its a figment of an OO author's imagination only.


Similarly you should be able to explain why/how 1-5 can/cannot be
resolved with various programming paradigms/constructs/techniques.


Regards,
Steven Perryman

-T-
oop.ismad.com
.



Relevant Pages

  • Re: Gonzales, Another one bites the dust.
    ... Poor Keith is still feeling left out of it after members left his ... coup on who releases MASM32. ... Is this why you tried to get Paul Brennick's rights to use MASM from ... blip in the programming world. ...
    (alt.lang.asm)
  • Which members are created automatically, which members are not inherited?
    ... into a deep sleep after a through night hard work. ... very important thing of C++ programming language? ... Which members will be created automatically? ... I know default ctor, copy ctor, dctor, assignment operator can not be ...
    (comp.lang.c)
  • Re: Admire the rentacoder.com
    ... Mr Howard is right to avoid discussing them. ... your programming ability than I do his. ... > This is always up to buyer: ... Let Zi, Zj, Zk be arbitrarily-chosen members of Z. ...
    (comp.programming)
  • Re: Why is Object Oriented so successfull
    ... Type substitutability is a good means of implementing the ... set, without affecting/impacting the other members (interface, impl). ... If you understand or have experienced the variant record problem, ...
    (comp.object)
  • Re: What do others make of this code?
    ... OOP, modular, procedural. ... > as classes with private or protected members would probably do little more ... Again, no invariants. ... tried and true methods of procedural programming. ...
    (comp.lang.cpp)