|
Posted by Tony Marston on 12/12/95 11:51
"Jerry Stuckle" <jstucklex@attglobal.net> wrote in message
news:HNadnet0zsaECjzZnZ2dnUVZ_uudnZ2d@comcast.com...
> Tony Marston wrote:
>>
>>
>> There is nothing special with messaging. It's a piece of code calling a
>> function, which has existed in many non-OO languages for decades. There
>> is no difference between calling a function and calling a method
>> (function) within an object.
>>
>> OOP is about encapsulation, inheritance and polymorhism, and the ability
>> to create objects from classes. It is taken for granted that there is a
>> method of communicating with each of the objets ou create. There is
>> nothing special about "messaging" at all.
>>
>
> Well, the fact is, messages (function calls) are OPTIONAL in other
> languages. You can build a C program without any functions (other than
> main()). You can build an assembler program with no subroutines.
While it is true that you can write a program which doesn't call any
subroutines or functions, it is still part of the language as standard.
> But OO *REQUIRES* messages.
So what? Messaging is the same as calling a function or subroutine, and this
is a standard feature of EVERY computer language. There is nothing in OOP
that makes it unique.
>>>However, wikipedia (which I also mentioned because it might meet your
>>>level of intelligence), says under "Fundamental Concepts":
>>>
>>>"Method (also known as message) how code can use an object of some
>>>class. A method is a form of subroutine operating on a single object
>>
>>
>> Other languages have had the ability to create subroutines, and to be
>> able to call those subrutines, for ages. There is nothing special about
>> that which only eists in OOP.
>>
>
> Sure, they *HAVE THE ABILITY*. In OO, you *MUST CREATE THEM*.
>>
>>>. Methods may be divided into queries returning the current state and
>>>commands changing it:
>>
>>
>> Other langages have had the ability for a module to have several entry
>> points, and for each entry point to do something different, for decades.
>> There is nothing special about his technique which is unique to OOP,
>> therefore saying that it is a fundamental priciple of OOP is entirely
>> misleading. AFAIAC it is a fundamental requirement of EVERY language, OO
>> and non-OO, to be able to call one module from another. This is a
>> standard requirement, there is nothing special aout it at all.
>>
>
> You just don't seem to understand the difference between *HAVING THE
> ABILITY* and *REQUIRING* something.
Your point is that messaging is a fundamental principle of OOP which sets it
apart from non-OOP languages. My point is that tyhe same feature exists in
ALL computer languages. If the only real difference is that in OOP it is
*REQUIRED* whereas in other languages it is *OPTIONAL* I think you are
making a mountain out of a molehill. The things which are supposed to make a
language OO instead of non-OO are only supposed to exist in OO languages, so
if messaging already exists in non-OO languages then it cannoit be a
fundamental principle of OO.
>>>a Dog could have a query Age to say how old it is, and command chase
>>>(Rabbit target) to start it chasing a rabbit. A method may also do both,
>>>but some authorities (e.g. Bertrand Meyer) recommend they be kept
>>>separate. Sometimes access to the data of an object is restricted to the
>>>methods of its class."
>>>
>>>It is important because that's how you communicate with objects. It's
>>>the interface, which is public, instead of the implementation, which is
>>>private.
>>
>>
>> Calling a function and passing parameters to it, and getting parameters
>> back, is not something which is unique to OO. It is a standard feature of
>> EVERY language, therefore to say that it is a fundamental principle of
>> OOP carries no more weight than saying the ability to declare variables
>> is a fundamental principle of OOP. It is oneof those obvious things which
>> should not have to be stated.
>>
>
> Sure it's a fundamental principal. Because OO *REQUIRES IT*.
That does not make it a fundamental principle in my book. If non-OO
languages did not have messaging then that would be a different matter, but
they do, so it isn't.
>>>But if you understood OO as well as you claim you would understand that.
>>
>>
>> The difference between an OO and a non-OO language is that one has
>> encapsulation, inheritance and polymorphism while the other does not.
>> Both have messaging (the ability to call functions) so that is a complete
>> red herring.
>>
>
> And OO *REQUIRES* message passing. Non-OO languages do not.
>
> You really ARE dense, aren't you?
Not as dense as you. The principles of OO are features that do not exist in
other languages. Having something which is required instead of optional DOES
NOT MAKE IT A FEATURE. Non-OO languages have had messaging for decades, so
messaging is not a fundamental feature of OO.
Encapsulation, inheritance and polymorphism do not exist in non-OO
languages, so THEY are fundamental principles. Messaging is not. The fact
that OO requires messaging while others do not is totally insignificant.
--
Tony Marston
http://www.tonymarston.net
http://www.radicore.org
Navigation:
[Reply to this message]
|