P is for Practical | |
PerlMonks |
Re: OO, inheriting functions from other packagesby perrin (Chancellor) |
on Jul 22, 2004 at 16:16 UTC ( [id://376637]=note: print w/replies, xml ) | Need Help?? |
Getting access to functions is not what inheritance is for. Inheritance is used when you have a class that is just like another class except for some variations in behavior of specific methods. Most of the time, the relationship between classes is "foo has a bar" not "foo is a bar." When in doubt, don't use inheritance.
In Section
Seekers of Perl Wisdom
|
|