Home > Articles > Home & Office Computing > Mac OS X

Interview with Aaron Hillegass

Scott Stevenson interviews Aaron Hillegass about the new edition of Aaron's book, programmers' fear of the NIB file, and why there aren't more Macs in corporate America.
Like this article? We recommend

Scott Stevenson: What sort of experience should a developer already have before reading Cocoa Programming for Mac OS X? Do they need to know anything about using Apple's development tools or Objective-C?

Aaron Hillegass: One of the most difficult things about writing a book is choosing your audience. It would be great to write a book that assumes nothing; anyone could read it. However, an experienced programmer would find the resulting book painfully tedious.

In the end, I decided to assume that readers are familiar with the C programming language and thinking in an object-oriented manner. The reader with this base knowledge will find Objective-C to be a rather unsurprising language, so the book moves quickly through the fundamentals of Objective-C and into the design patterns of Cocoa.

Scott: Conversely, how far does this edition take the reader? In other words, if a developer has already stumbled through the basics, knows the Objective-C syntax, and has compiled a few sample apps, will they find this book useful?

Aaron: I think the old adage rings true: "If you only know how to use a hammer, everything looks like a nail."

The typical self-taught Cocoa programmer has mastered a few concepts and uses them in every situation. By going through the book from beginning to end, the reader gets familiarity with a large collection of ideas and technologies. This deeper understanding results in better, more reliable applications — because the reader uses the Cocoa frameworks as they were intended to be used.

The book doesn't cover everything — that would take thousands of pages — but I have done my best to identify and explain the concepts that the average Cocoa programmer uses on the average day.

There is also some interesting feedback in the system: Because my book has become the standard approach to learning Cocoa programming, a lot of documentation and discussion on the internet assumes that the audience has read it. Thus, the chapters in the book now represent the core knowledge that every Cocoa programmer is expected to have.

Scott: I see that you've refined many of the existing chapters, as well as added brand new material. Which new chapter did you find the most interesting to write, and which existing chapter received the most re-working?

Aaron: For years, I have taught students in my classes how to do view swapping in an elegant, maintainable way. With 10.5, Apple added the NSViewController to Cocoa. It isn't nearly as glamourous as Core Data or Core Animation, but I think the chapter on View Swapping was the most satisfying addition because it is a technique that Cocoa programmers use daily.

The NSArrayController chapter was reworked so much that it eventually underwent mitosis and became two chapters: One dedicated just to the ideas of Key-Value Coding and Key-Value Observing and a second devoted to the mechanics of using these ideas with NSArrayController.

Scott: I've seen emails from novice developers who liked the way the previous editions of the book were written, but were confused how they didn't match up with the recent changes in Mac OS X 10.5 Leopard. Has all of that been addressed now?

Aaron: If Apple would just stop innovating, I would stop rewriting this book and write new ones instead. Yes, the third edition is now up-to-date with Xcode 3.1 and Mac OS X 10.5.

The world outside Apple has also been changing. For example, web services have also become very important, so I added the web services chapter to the book.

Scott: What was the most challenging part of writing this edition of the book?

Aaron: The technologies documented in the first and second edition of the book had been around for a decade, and the community had developed a set of common idioms and best-practices. I could authoritatively say, "This is how we do it." The new technologies — Core Animation, Garbage Collection, and Core Data — don't have a deep history. No one can speak about their use with complete authority. I did my best to study how the engineers who created them wanted the technologies to be used.

Scott: Is the material in this book a good starting point for developers looking to hit the ground running with the iPhone SDK, or are the development concepts too different? Do you plan to write a book specific to iPhone development?

Aaron: There is, at this point, no better starting point for iPhone development than "Cocoa Programming for Mac OS X." If you understand the book, you can get started with iPhone development. There are ideas that have changed — for example, controls on the iPhone can have multiple targets and actions — but they have evolved naturally from the ideas of Cocoa programming.

In September, Big Nerd Ranch (my company) will debut its iPhone Development Bootcamp. That class, which will be every bit as brilliant as our Cocoa Bootcamp, is going to focus only on iPhone development. By removing ideas like the pasteboard, we create time and space for discussions of iPhone-specific topics like the CoreLocation framework and the accelerometer.

Perhaps that class will become a book someday, but we need to test and improve it in the classroom for a while first.

Scott: What would you say to new developers who are trying to figure out if they should learn Objective-C or use one of the Cocoa scripting bridges in Leopard? On a related note, what do you think about the comments from those who say Apple should have based the iPhone SDK on Java or C++?

Aaron: For fifty years, there has been a heated debate going on about programming languages. In the meantime, real programmers have been solving real problems with imperfect languages like Perl and Objective-C. Why?

Perl and Objective-C have three things in common:

  1. They come with incredible libraries. Perl has CPAN and Objective-C has Cocoa.
  2. They don't get in your way. Both languages have good performance and loose typing.
  3. They are easy to learn.

Ruby and Python are lovely scripting languages, and you can write Cocoa applications with them after you learn Objective-C!

Cocoa was written in Objective-C and for Objective-C. You will never really understand Cocoa until you understand Objective-C.

It is true that some people have voiced the opinion that the iPhone SDK should have been based on languages other than Objective-C. However, it is important to note that none of these people have ever shipped an application written in Objective-C. Anyone who has used Objective-C knows that it is an able work-horse.

Scott: What do you think are the most common misconceptions that new Mac developers have coming from Windows, Java, or even traditional C++ GUI toolkits?

Aaron: Fear of the NIB file. Experienced Cocoa programmers put a lot of the smarts of their application in the NIB file. As a result, their project has a lot less code. Programmers who have spent a few years working in Visual Studio get freaked out. They ask me stuff like, "Can I write Cocoa apps without using Interface Builder? I like to see the code. Maybe I can just explicitly create my windows and the views that go on it?"

It is difficult to explain how the NIB file (and a few other scary ideas) create leverage. It is that leverage that enables one guy in his basement to compete with a team of engineers at Microsoft or Adobe. It is like I showed a chain saw to a early American colonist, and he said, "Can I cut down the tree without starting the engine? I don't like the noise. Maybe I can just bang it against the tree?"

Scott: I think a lot of developers wonder how to get their work noticed by potential employers, customers, and the community. Do you have any suggestions?

Aaron: One of the nice things about the Mac community is that quality gets noticed. People love their Macs, and anything or anyone who can make it better will get recognized in blogs and discussion groups and magazine articles. The Mac community has been very kind to me; people have spent a lot of energy explaining the strengths and weaknesses of my books and my classes. I couldn't be more grateful.

Scott: What sort of effect do you think the iPhone will have on the Mac development community? Do you think they'll divide into separate camps, or is it more likely that the lines will blur? Do you expect to see an influx of new Mac developers from the iPhone?

Aaron: It is a great time to be a Cocoa programmer. Apple is selling 50% more Macs than they did a year ago. They are selling iPhones by the boatload. The Cocoa community is, in the grand scheme of things, rather small right now. I suspect that it will double in size over the next two years. Everyone in that community will know how to write code for either device.

But! A good iPhone app is going to be very different from a good Mac app. iPhone apps are going to be smaller and simpler. Overall, I suspect that a brilliant iPhone app will take six months to write, while a brilliant Mac app takes five years. I suspect that there will be two camps — not because the skill sets are different, but because iPhone programmers will have different personalities and proclivities than Mac programmers.

Scott: The Mac appears to be making real inroads in the mainstream consumer computing market, and certainly the iPhone is doing the same. Do you expect to see this carry over to the corporate world?

Aaron: Apple seems to doing its best to keep Macs out of the corporate world. Most dialogues between Apple and a corporation go something like this:

Scott: What do you find most rewarding about the books you've written and the classes you've taught? Seeing the light go on in the student's head, seeing them ship an app, or something else?

Aaron: I'm a good programmer — I've written large medical, military, and financial systems — but that is not my calling. I am a teacher, and I live to get people to "Aha!"

Over my career, I've developed and tested many theories about teaching and learning. Now, I want to make these ideas manifest in a physical form. I have purchased some land, and I'm working with architects to design an environment for learning — the new Big Nerd Ranch.

Scott: Mac development has changed a lot in the last few years, and dramatically so in the last six months. What sort of things surprise you when you see them now versus how things were when the first edition of the book came out in 2002?

Aaron: I think people overestimate how much has changed since 1991. If we thawed out a developer who had been writing an app for the NeXT computer in 1992, he would not feel out of place on Mac OS X 10.5. The last 16 years have been spent making significant, but evolutionary, steps toward fulfilling the promises embodied by the elegant ideas in NeXTSTEP 1.0.

Scott: When you're not busy writing, do you spend most of your time teaching classes in person, or are you involved in other projects?

Aaron: I teach about a dozen classes each year. I continue to help our clients write applications for the Mac, and now the iPhone, but as Big Nerd Ranch grows, I spend more and more of my day being a business guy. We are always developing new courses on technologies like Django and Android — I spend a lot of time editing these new courses.

Scott: Will you be at Apple's Worldwide Developers Conference in June? How should developers that want to meet you in person at the conference try to track you down?

Aaron: I'll be at WWDC, and I'm always happy to meet new people. I am pretty easy to spot — I'm quite tall and I wear a cowboy hat. Please come say hello.

Scott Stevenson runs Cocoa Dev Central and theocacao.com, which help programmers learn how to write software for the Mac. Scott also owns a tiny company called Tree House Ideas.

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information

To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.


Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.


If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information

Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.


This site is not directed to children under the age of 13.


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information

If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information

Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents

California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure

Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact

Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice

We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020