[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Programming it's a play

From: Dennis Leeuw
Subject: Re: Programming it's a play
Date: Sun, 21 Sep 2003 16:31:22 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.0) Gecko/20020623 Debian/1.0.0-0.woody.1

Pascal J.Bourguignon wrote:
Pete French writes:

I do want to know what this means. Can someone that writes a class, like the Greeter example write his own Class methods or are Class methods just inherited from the root class. Meaning you can only add instance methods.

You can add your own class or instance methods as you like. As long as you
bear in mind that yopu are adding them to a completely different object to the
instance methods.

What is your view on a class (remember I am a VERY newbie). How can you send a message to a class when a class is not an object.

A class *is* an object - whos primary purpose is to create other objects.
trying to make a distinction between the written description and the
compiled version (which you seem to be trying to do) is only going
to confuse things.

you cannot say if doBar is an instance method or a class method, (it's
none, it  is a message!),  or if  foo refers a  class or an  object (a
class IS an object so it does not matter).

Okay let's say I forget about the Apple documentation. And thus we say a Class IS an object. And to prevent the chicken and egg problam some looney invented the meta-class to overcome this.
Then how about the Class object? Should we forget that one too?

Although I think I will keep using a simplified metaphore within the Guide. But getting the whole concept clear will make it possible for me to comment in a later chapter on the example.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]