Network notifications
Network notifications
- Subject: Network notifications
- From: Randall Meadows <email@hidden>
- Date: Mon, 31 Mar 2008 12:23:25 -0600
My app registers a bonjour service, but basically it's really just
advertising the web server running on the same machine as my app, with
a little extra information pertaining to my app. My app places files
in a known location in the hierarchy that apache is serving, and I
need to send out a notification when I make a change that's visible
via that hierarchy, so that remote apps can pick up the changes. The
docs for NSDistributedNotificationCenter say I need to use distributed
objects to communicate this fact to other computers (not just
processes on my own). But to use DO, there needs to be a known
connection between my app and the remote app, right? We don't want
this connection, hence our move to serving these files via the built-
in web server. (I have control over this remote app, and can make it
listen for whatever I want.)
I tend think NSNetService is what I want; it's what I use for the
registering the service to begin with, but it's unclear to me how I
can use that for momentary notifications ("this file changed", "this
file is new"), as opposed to notifying about a long-lived service
("here's a web server"). And taking a brief look at
NSNetServiceBrowser, I can see how to easily find the service to begin
with, but it's not obvious how it would be notified of the changes
without re-searching for the same service it already knows about.
Is there some sort of NSNotification variant that I've missed for use
between remote apps (not on the same machine, but on the same LAN)?
Thanks!
randy
_______________________________________________
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