Re: Finding "myself" in a plugin architecture
Re: Finding "myself" in a plugin architecture
- Subject: Re: Finding "myself" in a plugin architecture
- From: Shawn Erickson <email@hidden>
- Date: Tue, 20 Feb 2007 08:40:37 -0800
On Feb 20, 2007, at 8:25 AM, R. Tyler Ballance wrote:
On Feb 20, 2007, at 8:53 AM, August Trometer wrote:
You could always use:
[[NSBundle bundleForClass:[self class]]
This is something I had thought about, but after a bit of
experimentation, it kept returning the framework bundle inside my
plugin instead of the plugin itself, so I instead opted for going
with the identifier instead.
It returns the bundle that the class was loaded from... which in this
case it sounds like is a framework bundle you have inside of a plugin
bundle. IMHO it seems a little weird to have the framework attempt to
look outside itself, if you are doing that why not just compile that
code directly into the plugin code.
If you want such separation... I personally would design things such
that top level plugin code would tell or provide a factory to the
framework code to allow access to what it needs.
-Shawn
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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