• 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
Difference between @synchronized and [managedObjectContext lock]?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Difference between @synchronized and [managedObjectContext lock]?


  • Subject: Difference between @synchronized and [managedObjectContext lock]?
  • From: Laurent Daudelin <email@hidden>
  • Date: Tue, 29 Nov 2011 12:08:43 -0800

I'm working on some code that I didn't write and have some core data areas that use [managedObjectContext lock] and [managedObjectContext unlock] while other areas in the code uses @synchronized. I know that @synchronized is a convenience to create a mutex lock so that not 2 threads can acquire the same lock at the same time but are there other differences? Is one better than the other?

Thanks for any insight on this!

-Laurent.
--
Laurent Daudelin
AIM/iChat/Skype:LaurentDaudelin 				http://www.nemesys-soft.com/
Logiciels Nemesys Software					email@hidden

_______________________________________________

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: Difference between @synchronized and [managedObjectContext lock]?
      • From: Dave Fernandes <email@hidden>
  • Prev by Date: Re: How to display HTML in proper format in a NSTextView
  • Next by Date: Re: Difference between @synchronized and [managedObjectContext lock]?
  • Previous by thread: Re: Weird Core Data crash
  • Next by thread: Re: Difference between @synchronized and [managedObjectContext lock]?
  • Index(es):
    • Date
    • Thread