• 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: NSNotifications & background apps?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSNotifications & background apps?


  • Subject: Re: NSNotifications & background apps?
  • From: "Hamish Allan" <email@hidden>
  • Date: Sun, 15 Jun 2008 20:38:57 +0100

On Sat, Jun 14, 2008 at 8:52 PM, dream cat7 <email@hidden> wrote:

> Seeing notifications from outside:
> [...]
> Sometimes 2 process are
> communicating And one of them is launching / closing multiple times during
> the session (e.g. sending kill message as NSNotification).

You refer to NSNotification many times in your post, but
NSDistributedNotification only once or twice; I assume from the
context that you always mean the latter.

> Indeed I am not shifting around any large volumes of data at the moment, it
> is maybe 10 or so application preferences settings, with a 2-3 of data
> objects which are archived with NSCoding/NSArchiver protocol. However as my
> application becomes more enhanced, there may be significantly more such
> "medium size" data object.

Why not put the data files somewhere else, i.e., Library/Application
Support? Then you can distinguish between changes in preferences and
changes in data, break down the atomicity of your data as far as you
like, easily write Spotlight plugins, etc.

> With a launchd - administered  process they can be started at any time. But
> is it reasonable to believe that the daemon can start running before the
> NSNotification centre and then some time after it started that it can
> register with the notification centre when it becomes available ?

I don't know, but I'd imagine that if you call
+[NSDistributedNotificationCenter defaultCenter] before the center
exists, it will be created.

Hamish
_______________________________________________

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

References: 
 >NSNotifications & background apps? (From: dream cat7 <email@hidden>)

  • Prev by Date: Re: iPhone SDK build of default application fails
  • Next by Date: Re: Converting to NSPersistentDocument
  • Previous by thread: Re: NSNotifications & background apps?
  • Next by thread: Transparent content view of NSWindow clicks through
  • Index(es):
    • Date
    • Thread