One possible adjustment for this is to keep your PERSON class, but instead of subclassing it, create an OCCUPATION (or a different term to represent 'relationship to your program' without using RELATIONSHIP) base class; PERSON would then have as an object member a one-to-many array of OCCUPATIONs. Your VENDOR, CUSTOMER, and EMPLOYEE classes then subclass from OCCUPATION.
*subject to one's personal interpretation of the matter; some people believe multiple inheritence is a work of pure evil, some believe it's manna. I'm of the opinion that if you believe the only solution is multiple inheritence, you've got something wrong in your object model.
-----------------------------------------------------
Dr. Michael K. Neylon - mneylon-pm@masemware.com
||
"You've left the lens cap of your mind on again, Pinky" - The Brain
It's not what you know, but knowing how to find it if you don't know that's important
In reply to Re: Objects in PERL
by Masem
in thread Objects in PERL
by Vuud
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |