[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Defininng and using an object as a Swarm and a SwarmObject at the same t
From: |
William S. Shu |
Subject: |
Defininng and using an object as a Swarm and a SwarmObject at the same time. |
Date: |
Fri, 19 Mar 1999 18:27:00 -0000 |
Please help me find practical ways of expressing the following conceptual
problem in Swarm (and adhere to Objective C requirements as well)
exemplified by:
@interface MalariaPop:Population:SwarmObject
{
...
}
...
@end;
@interface MalariaPop:Population:Swarm
{
...
}
...
@end;
MalariaPop is a population of malaria germs, and hence it is a kind of
population. Inside a person, I am interested in the malaria population as
an object, and so I define it as a swarmObject. But MalariaPop contains
malaria germs, whose interactions I may also want to consider. So I define
MalariaPop as a Swarm!
Using different names (e.g. MalariaPopSwarmObject and MalariaPopSwarm) seems
to make two classes of the same thing, and I would probably have to allow
for this distinction in the code.
Now the Questions (probably trivial):
a) How can one define a given object simultaneously as a Swarm and a
SwarmObject.
b) Having successfully defined it, any hints on how to switch between its
two "states", or those in between? i.e., to be treated completely as an
object, or completely as a swarm, or simultaneously (?) as a bit of both!
c) How do I avoid defining intermediate classes for Population:Swarm,
Population:SwarmObject. They are not a result of my problem conception and
seem to distract. At any rate, if they must exist, how do I hide them and
ensure they are "transparent"?
Thanks,
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.
- Defininng and using an object as a Swarm and a SwarmObject at the same time.,
William S. Shu <=