This is a long overdue post about the book iPhone in Action. It's not a complete review as I haven't finished it yet: Mainly because I don't have enough time, but also due to the fact the kind guys at Manning sent me the PDF version (disclaimer: for free).

The book is split into two parts: Web applications tailored for the iPhone and using the iPhone SDK. I have only read the second bit, and not in-depth, given how I realised I hate reading PDFs, and the lack of any decent PDF reader for the iPhone (if you happen to know one, please tell!).

Overall, the book is very well written. The Manning copy editors do a very good job, there was no place where I had trouble understanding, everything was clear and nice. The content is incremental, and you get nice pointers to previous chapters in case (like me) you're cherry picking chapters you're interested about. At the end of every chapter you get links for further reading, especially useful where they're touching complex issues . I would say it's very well suited to beginners and people who don't know much about programming on a Mac.

What it covers

Here's a quick rundown of the contents:

Chapters 1 and 2 are an introduction the the iPhone as a device, hardware capabilities and tech-specs, and a comparison of the two ways of developing applications for it (web and SDK).

The web

Chapters 3 to 9 cover developing web applications on the iPhone. I've only read chapter 3 which covers how to optimise existing sites for the iPhone. Very well written, explains all the concepts you need to understand like viewports, events, CSS optimisations and user agent detection. Chapter 4 covers advanced WebKit functionality like CSS transforms and gradients, the database and gestures. Chapter 5 covers the iUI library, chapter 6 using Canvas and chapter 7 building web applications using Dashcode.

The SDK

Chapters 10 to 20 cover developing applications using the iPhone SDK. I've read most of them, and enjoyed it.

Chapter 10 introduces you to Objective-C and the iPhone OS. Chapters 11 and 12 introduce you to Xcode and Interface Builder, and you create your first "Hello, World!" project. Chapter 13 covers view controllers, a cornerstone of building iPhone apps. Chapter 14 covers events and actions: the responder chain, buttons, textfields and notifications. Chapter 15 shows some more view controllers, like the tab bar controller and the navigation controller, both major tools for applications.

Chapter 16 covers writing and reading to files, SQLite, preferences and access to the Address Book. Chapter 17 shows how to use the accelerometers and Core Location. Chapter 18 introduces media: displaying images, accessing photos, the Media Player framework and other audio cases. Chapter 19 gives a taste of Quartz, Apple's drawing framework, and Core Animation. This is the chapter I plan to read again, as for my current project I use both heavily and a good overview would be nice, if only to confirm my understanding.

Lastly, chapter 20 covers interacting with the web - a very well thought addition since most applications will want to follow URLs, show web pages, parse XML responses and POST to a server, all of which is covered, including an introduction to low-level networking.

Conclusion

Overall, I like this book. I enjoy the style and the bite-size approach. My experience with Apple's documentation is that it's thorough but sometimes fails to give you a coherent overview on how things should be used or how everything fits together. I think this book fills that role very well. If you already know Cocoa and understand its architecture, everything should slide into place neatly and you can skip most introductions. If it's your first time with Cocoa and Objective-C, you should get enough help to get started and pointers to expand your knowledge.

Overall, I'd suggest it!

April 3, 2009, 1:24 a.m. More (650 words) 0 comments Feed
Previous entry: Key-Value Coding in PyObjC
Next entry: What I've been up to

This post is older than 30 days and comments have been turned off.