Re: Multiple inheritance and objective-c
Re: Multiple inheritance and objective-c
- Subject: Re: Multiple inheritance and objective-c
- From: Ben Golding <email@hidden>
- Date: Tue, 22 Mar 2005 11:38:48 +1100
On 22/03/2005, at 11:09, Mark Dawson wrote:
If you own B and can do what you want with it, and assuming that B
and C have 10% different from each other. Then a few of options I
see are:
- Add the 90% to A and subclass both B and C from A
Maybe I wasn't clear--class A's functionality has nothing to with C's.
The shared functionality has to with what B is adding to A (via the
subclass).
Maybe your class hierarchy is inverted, that is, maybe A should inherit
from B rather than vice versa? Then C could also inherit from B to
pick up the functionality it needs.
There is such an abstract description of the problem at hand, it's hard
to know how to best solve it. Perhaps the use of a delegate might help
but I'm not sure.
Ben.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden