• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Finding "myself" in a plugin architecture
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Finding "myself" in a plugin architecture


  • Subject: Re: Finding "myself" in a plugin architecture
  • From: August Trometer <email@hidden>
  • Date: Tue, 20 Feb 2007 09:53:13 -0500

You could always use:

[[NSBundle bundleForClass:[self class]]


August



On Feb 20, 2007, at 9:44 AM, R. Tyler Ballance wrote:

I'm following the Code Loading Programming Topics guide to work on implementing a relatively basic plugin architecture for an application of mine. The one thing that I "can't" seem to do is "find myself" from the plugin's perspective.

Insofar as [NSBundle mainBundle] will return the main application bundle. Is there a way that I'm missing that I can find "my" bundle from inside the plugin's code itself? So I can access my own Info.plist file, among other things. Any ideas?

While I could use [NSBundle bundleWithIdentifier] that's a bit too case-centric in that this "dumb" bit of code would have to know what the identifier of the bundle is that it's being loaded in is, as opposed to using reflection (eeek) and discovering this at runtime.


Cheers R. Tyler Ballance: Lead Mac Developer at bleep. software contact: email@hidden | jabber: email@hidden


_______________________________________________

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

_______________________________________________

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


  • Follow-Ups:
    • Re: Finding "myself" in a plugin architecture
      • From: "R. Tyler Ballance" <email@hidden>
References: 
 >Finding "myself" in a plugin architecture (From: "R. Tyler Ballance" <email@hidden>)

  • Prev by Date: Finding "myself" in a plugin architecture
  • Next by Date: Re: Cross Nib communication
  • Previous by thread: Finding "myself" in a plugin architecture
  • Next by thread: Re: Finding "myself" in a plugin architecture
  • Index(es):
    • Date
    • Thread