swarm-support
[Top][All Lists]
Advanced

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

Re: Big diatribe on protocols & classes (was Re: Can a Swarm instancebe


From: William S. Shu
Subject: Re: Big diatribe on protocols & classes (was Re: Can a Swarm instancebe treated like a SwarmObject instance?
Date: Fri, 23 Apr 1999 11:10:36 +0100

>"Marcus G. Daniels" wrote:
>>
>> >>>>> "PJ" == Paul E Johnson <address@hidden> writes:
>>
>> PJ> So, I think to understand the problem, one ought to remember that
>> PJ> the list of methods in the protocol listing is not an exclusive
>> PJ> list of methods that an object can carry out.
>>
>> Note, though, that Swarm advertises its features with protocols.  If
>> you use a method that isn't advertised, directly or indirectly by
>> protocol inheritance, you are relying on behavior is not specified (not
good).


I agree.  It is very unsafe to use protocols/methods/interfaces that are not
guaranteed, especially as subsequent upgrades could change things.

Paul indicated earlier that Swarms have all the protocols of SwarmObjects.
Perhaps this should be formally stated that Swarms are a "special kind of"
SwarmObject (not necessarily via inheritance).  If we are to have swarms of
swarms, or fully exploit the power of object-orientation, I think this would
be inevitable.  This can be done in one of two ways:

EITHER
    A Swarm is a kind of SwarmObject in the inheritance/subclass sense.
That is, a Swarm is [a descendant] subclass of a SwarmObject.  This could be
tricky as it involves rewrite of code.

OR
    A Swarm is a "parallel kind of" of SwarmObject.  A Swarm (at interface
level) does all the things that a SwarmObject does.  However, it is *NOT* a
subclass (descendant) of a SwarmObject.  In effect, it implements all the
protocols of the SwarmObject protocol.


William.




                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.



reply via email to

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