-1

This is the documentation in iOS 6

Users are able to grant or deny access to contact data on a per-app basis. To request // access to contact data, call ABAddressBookRequestAccessWithCompletion. This will not // block the app while the user is being asked to grant or deny access. Until access has // been granted, a non-NULL ABAddressBookRef will not contain any contacts and any attempt to // modify contacts will fail with CFErrorRef returning kABOperationNotPermittedByUserError. // The user will only be prompted the first time access is requested; any subsequent calls // to ABAddressBookCreateWithOptions will use the existing permissions. The completion // handler is called on an arbitrary queue. If the ABAddressBookRef is used throughout the app, // then all usage should be dispatched to the same queue to use ABAddressBookRef in a // thread-safe manner

It doesn't say same thread anymore. Just same queue. So it's okay to use NSOperationQueue to access this ABAddressBookRef? Can I?

Note: That question ask whether we can tell NSOperationQueue to use one specific thread. This one ask if ABAddressBook can be used ACROSS threads within the same NSOperationgQueue (perhaps a serial one)

There are 2 DIFFERENT way to accomplish the same thing. Hence the question is different.

GoGauchos
  • 588
  • 5
  • 11
user4951
  • 32,206
  • 53
  • 172
  • 282
  • possible duplicate of [Besides the main thread is there any other special thread?](http://stackoverflow.com/questions/19176659/besides-the-main-thread-is-there-any-other-special-thread) – trojanfoe Oct 04 '13 at 08:39
  • Why are you posting multiple questions about the same topic? I would recommend spending more time on the Apple Developer site. – trojanfoe Oct 04 '13 at 08:40
  • That question ask whether we can tell NSOperationQueue to use one specific thread. This one ask if ABAddressBook can be used ACROSS threads within the same NSOperationgQueue (perhaps a serial one) – user4951 Oct 04 '13 at 10:29

1 Answers1

0

You cannot use across different jobs of an operation queue, because jobs may be dispatched on different threads.

Léo Natan
  • 56,823
  • 9
  • 150
  • 195