PDA

View Full Version : A few questions about NSOperation




idelovski
Jul 26, 2010, 04:45 PM
Just made my application store images to an SQLite database in background thread using NSOperationQueue and NSOperation and at first glance it seems to work nicely, but I have a few questions.

1. Do I need to have only one instance of NSOperationQueue in my application or can I have one for database things, another in charge of web requests and another doing some other stuff? Can they operate at the same time? Should they?

2. What happens when I receive -applicationWillTerminate: or similar messages? Do I need to check somehow if there are operations still in the queue?