Review of "Programming iOS 4" by Matt Neuburg

I teach a series of iOS Developer courses in the city of Ottawa, ranging from Beginner to Advanced, and covering topics just about everywhere in between. The course is mostly based on content I've written myself, but it also depends on a textbook for supplimental material.

When the courses started in November 2010, the textbook I chose for the course was Erica Sadun's iPhone Developer's Cookbook. Though book focused on iOS 3, as iOS 4 was still novel enough to not have any published books at the time, most of it was still very relevant, even as the course began with iOS 4.1. However, I was never completely satisfied with the book. I found it focused on the wrong types of tasks, had questionable code examples, and just seemed to go in the wrong direction. Of course, being a Cookbook, it wasn't exactly intended to be a complete tutorial. It was, however, the best choice at the time.

In the Spring of 2011, I began my search for a newer and better textbook to be used for the Summer's offerings, hopefully one which could cover Beginner-to-Advanced topics. I was lent a review copy of Matt Neuburg's Programming iOS 4 from O'Reilly publishing, to evaluate for my future class offerings.

I immediately fell in love with this book. Even from the table of contents, I could tell this was going to be the book for my course going forward.

The book, which is relevant up to iOS 4.3 (the most recent shipping version of iOS even as of this writing), and uses Xcode 4, also the most recent version of the development environment, covers essentially every single topic a developer will need to go from ignorance to bliss with the iOS platform.

Matt sums up the book rather well in his preface:

The widespread eagerness to program iOS, however, though delightful on the one hand, has also fostered a certain tendency to try to run without first learning to walk. iOS gives the programmer mighty powers that can seem as limitless as imagination itself, but it also has fundamentals. I often see questions online from programmers who are evidently deep into the creation of some interesting app, but who are stymied in a way that reveals quite clearly that they are unfamiliar with the basics of the very world in which they are so happily cavorting.

It is this state of affairs that has motivated me to write this book, which is intended to ground the reader in the fundamentals of iOS.

This 810-printed-page tome starts at the fundamentals, with a whole group of chapters forming a Language section: beginning with “Just enough C”, “Object Oriented Programming” and finally three more chapters introducing you to Objects in Objective-C, Classes, and other language features. These chapters provide the foundation for the rest of the book.

The next section prepares the reader for dealing with the Xcode development environment. Not only does Neuburg lay out the fundamentals of the Xcode app itself, he also goes through the parts of an Xcode project, which many learners find bewildering. Neuburg helps demystify it.

Additionally, and perhaps most commonly overlooked in most educational resources for iOS (excluding my course, natch), he devotes an entire chapter to Apple's provided Documentation, not only online, but as it exists in Xcode. He details how to read a Class Resource doc, and also where to look for help, be it a Programming Guide, Header file, or even Sample Code. Apple's Documentation is a crucial part to any iOS developer's toolkit, and it is finally given the attention it deserves in this book.

After nearly 200 pages, the book introduces the Cocoa section, with chapters detailing more advanced Language features like Categories and Protocols, and it also begins to focus on the crucial Foundation Kit of model classes. These classes are essential no matter which app you're building, and Neuburg gives them a thorough going over.

Continuing in the Cocoa section, the book moves on to describe the Cocoa Event's system, an incredible overview of the Memory Management rules for Cocoa, and some of the design patterns used throughout the frameworks such as Model-View-Controller and Delegation.

The next section moves on the the View and Drawing system of iOS, with chapters detailing UIView and its subclasses, how Animation and Drawing work, and the important relationship between Core Animation layers and the UIView class. Touch handling (include Gesture Recognizers) is also given a thorough detailing.

Neuburg continues to deliver on higher level and important sections, such as the Interface section, covering View Controllers and their role in applications, Scrolling views and Table lists (perhaps one of the most important classes of an iOS Application), the Text system, and a plethora of other commonly used interface elements.

The last two sections of this textbook focus on most all other frameworks of Cocoa touch, and topics like persistence, some networking and multithreading. About the only topic not covered in this book is Core Data, though it could easily be an entire book unto itself.

Programming iOS 4 is perhaps the best iOS book I've ever encountered, acting as the perfect companion to either an iOS bootcamp course, like the one I offer, or just a companion to solo journeys. It provides a sturdy foundation, and then builds on it. Even if you consider yourself an iOS expert, you still stand to learn something from this book, just like I did.

Speed of Light