Running a daemon
Running a daemon
- Subject: Running a daemon
- From: Ivan C Myrvold <email@hidden>
- Date: Wed, 18 Jun 2008 14:07:50 +0200
I have developed a daemon that have an Objective-C class
"ApplicationWatcher" which checks the foreground applications with
NSWorkspace.
In my main I create the ApplicationWatcher, and the class starts an
NSTimer.
This is probably a stupid question, but I want the daemon to continue
running, but at the end of main the daemon quit, even if I have an
NSTimer running.
So what should I do in main to have the daemon running?
In an ordinary Cocoa application the main contains "return
NSApplicationMain(argc, (const char **) argv);", but as this is a
daemon I can't call this.
Ivan
_______________________________________________
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