• 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: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!


  • Subject: Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!
  • From: Ken Thomases <email@hidden>
  • Date: Wed, 31 Mar 2010 17:12:20 -0500

On Mar 31, 2010, at 5:03 PM, Jerry Krinock wrote:

> So Ken I believe you're saying that the "cancelled" operations become ready to run immediately, which they do (as no-ops), which removes them from the queue.  In *effect* therefore, "are cancelled before they begin executing" *does indeed* == "removed from queue".

Yes, with the caveat that it can take some time.  An arbitrary amount.

> But maybe this is not true in 10.5?

On 10.5, -cancel does not make the receiver ready.  So, it still has to wait to become ready in the normal way.  If you haven't overridden what readiness means, then the operation just has to wait for all of its dependencies to finish.  You can remove the dependencies at the same time you cancel the operations, if you like, but there's no one-method way to do that.

Cheers,
Ken

_______________________________________________

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: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!
      • From: Jerry Krinock <email@hidden>
References: 
 >-[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?! (From: Jerry Krinock <email@hidden>)
 >Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?! (From: Mike Abdullah <email@hidden>)
 >Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?! (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!
  • Next by Date: Creating thumbnail of PDF document first page?
  • Previous by thread: Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!
  • Next by thread: Re: -[NSOperationQueue cancelAllOperations] cleans queue, but not immediately?!
  • Index(es):
    • Date
    • Thread