[Modeling] Modeling an Agent Class- register your opinion

James Odell email@jamesodell.com
Sat, 21 Jun 2003 12:10:47 -0400


>> This issue can be easily solved using Role Modelling:
>> A employee is not a class, it is a role that an object of the
>> class person can perform. Thus, if a department is destroyed, all
>> its employees lose this role becoming only persons (performing the
>> other roles they have, i.e. father, engineer, ...).

If all the employees for a department lose their jobs, they just have one
less role that they are instances of.  They do not "become" persons; they
already are persons.  So, is Juan was an instance of Employee, Homeowner,
and Father before his department was "destroyed," he is still a Homeowner
and Father after.


> What is a role in object orientation? According to the OO philosophy that
> 'everything is object', the answer can only be that roles are objects. Of
> course, they are defined through class, i.e. instances of class. This hights
> why OO does not modelling the world in a straightforward way, but one needs
> to twist their minds and arms to view the world.

Hong, excuse me: this is what metamodeling --not OO-- is about.  Why do you
make the claim that this "does not modelling (sic) the world in a
straightforward way"?  Metaclasses are classifiers whose instances are
classifiers.  This is very straightforward -- and is certainly not about
twisting the arm of "the world."  Individual roles, then, can quite easily
be expressed as instances of the class Role.  Employee is an instance of
Role, Homeowner is an instance of Role, etc..   In this context, then,
Employee and Homeowner *are* objects, which are instances of the class Role.
If you believe that Employee and Homeowner roles should be treated as
autonomous, interactive entities (i.e., agents), they are *still* instances
of Role. 
     In short, this has nothing to do with OO causing people to "twist their
minds and arms to view the world."   Therefore -- with all due respect -- I
strongly suggest we have heard enough of the OO bashing.  Instead, I
recommend that we all start recommending *solutions*.  At the end of the
day, it will be solutions that build systems.  So, please let's be
constructive here.


 
>> There are a lot of papers on how to implement roles in the OO
>> paradigm, but we think most appropriate approach is such that use
>> Aspect-Oriented Programming where functionality and behaviour are
>> orthogonal in the implementation.
If I understand the point you are making, I don't agree. Both OO and AO make
the distinction "where functionality and behaviour are orthogonal in the
implementation."    Again: I think it's time to start recommending solutions
that will solve the problems we need for agent-based systems.  Then, if the
solutions look good, we can look back to see if they are different from OO
or not.  Does that make sense?

-Jim