objc [66375] class Foo is implemented in both BundleA and BundleB
objc [66375] class Foo is implemented in both BundleA and BundleB
- Subject: objc [66375] class Foo is implemented in both BundleA and BundleB
- From: Jeff Szuhay <email@hidden>
- Date: Tue, 10 May 2016 23:05:24 -0700
Class Foo is a base class. It is subclassed in BundleA, BundleB, … BundleZ.
The runtime still throws that message, regardless. There are one or two
methods implemented in the base class and not in the subclasses.
You can see this effect if you download, build, and run Apple’s BundleLoader
sample program.
Is this a real issue? or an artifact of inheritence?
Is there a better way to do it? I can’t currently how to have a singleton base class
implementation that is shared among two or more bundles.
I suppose I could implement the base class in the bundle loader but that seems
to engender too tight a coupling between the bundleLoader and its bundles.
(smells bad).
A protocol will solve it but is undesirable since the base class methods would then
have to be duplicated in each subclass (smells bad).
If using a category is the solution, I suppose then I’m asking for a good example of
that. (Maybe BundleLoader could be revised to show that.)
Thanks,
Jeff
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden