• 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: Executing a very low-priority operation in iOS
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Executing a very low-priority operation in iOS


  • Subject: RE: Executing a very low-priority operation in iOS
  • From: Julius Oklamcak <email@hidden>
  • Date: Wed, 25 Apr 2012 20:50:27 -0400

> Normally I'd set up a timer to fire in a minute, set up an
NSBlockOperation,
> and let it go. When it finishes, I'd repeat the process. But I don't see
any
> way to adjust the priority of an NSOperationQueue.

NSBlockOperation inherits from NSOperation so you should be able to
-setQueuePriority: and/or -setThreadPriority: on it.

You could also use something like the following to run the block:

dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND,
0),
^{
	// ...
});

_______________________________________________

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

  • Follow-Ups:
    • Re: Executing a very low-priority operation in iOS
      • From: Rick Mann <email@hidden>
References: 
 >Executing a very low-priority operation in iOS (From: Rick Mann <email@hidden>)

  • Prev by Date: Re: WWDC
  • Next by Date: Re: Executing a very low-priority operation in iOS
  • Previous by thread: Executing a very low-priority operation in iOS
  • Next by thread: Re: Executing a very low-priority operation in iOS
  • Index(es):
    • Date
    • Thread