37

I'm just starting to use multithreading and was looking for a good explanation. I'm not sure if there are differences in how multithreading works on Macs and iPhones. What is a good link to tutorials with example code?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
nevan king
  • 112,709
  • 45
  • 203
  • 241

5 Answers5

18

A simple, but complete example is Multithreading in Cocoa.

And a related Stack Overflow question is NSOperation on the iPhone.

Community
  • 1
  • 1
Robert Harvey
  • 178,213
  • 47
  • 333
  • 501
11

Once again, if I may promote my iPhone development course, I had a class devoted to multithreading last semester, covering basic threading, locking, dealing with the UI on the main thread, and NSOperationQueues, for which the class notes can be found here. This fall semester that same class will be dominated by Grand Central Dispatch.

The video for the class can be downloaded for free from iTunes U.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Brad Larson
  • 170,088
  • 45
  • 397
  • 571
9

Don't forget the official documentation from Apple: Threading Programming Guide

You will find complete explanations and example code.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Thomas
  • 547
  • 5
  • 12
3

A good and short tutorial on NSInvocationOperation is Loading Images Asynchronously on iPhone using NSInvocationOperation.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Olof
  • 5,348
  • 4
  • 25
  • 27