Completely revised and updated, this new edition begins with some simple examples to familiarize you with the basic elements of Cocoa programming as well Apple's Developer Tools, including Project Builder and Interface Builder.
After introducing you to Project Builder and Interface Builder, it brings you quickly up to speed on the concepts of object-oriented programming with Objective-C, the language of choice for building Cocoa applications. From there, each chapter presents a different sample program for you to build, with easy to follow, step-by-step instructions to teach you the fundamentals of Cocoa programming. The techniques you will learn in each chapter lay the foundation for more advanced techniques and concepts presented in later chapters.
You'll learn how to:
Effectively use Apple's suite of Developer Tools, including Project Builder and Interface Builder
Build single- and multiple-window document-based applications
Manipulate text data using Cocoa?s text handling capabilities
Draw with Cocoa
Add scripting functionality to your applications
Localize your application for multiple language support
Polish off your application by adding an icon for use in the Dock, provide Help, and package your program for distribution
Each chapter ends with a series of Examples, challenging you to test your newly-learned skills by tweaking the application you've just built, or to go back to an earlier example and add to it some new functionality. Solutions are provided in the Appendix, but you're encouraged to learn by trying.
Extensive programming experience is not required to complete the examples in the book, though experience with the C programming language will be helpful. If you are familiar with an object-oriented programming language such as Java or Smalltalk, you will rapidly come up to speed with the Objective-C language. Otherwise, basic object-oriented and language concepts are covered where needed.
Fast forward to verison II, Learning Cocoa w/ Objective C. This book is great! It covers a whole slew of topics ommitted by the first version. Thankfully the content is NOT the same as before. A tiny bit of it is similar, but for the most part one person took it upon themselves to make sure that all of the material was presented in a consistent manner. By the end of this book you'll walk through all of the steps required to write an application similar to TextEdit (provided with Mac OS X). This application will support Rich Text Formatting, save and open capabilities, spell checking and much much more. You'll be impressed with what you build in this "Learning" book. If you've ever done the REALBasic tutorial you'll find that this creates a very similar application using the Cocoa Framework and Objective-C.
All the basics of learning to write MAC OS X applications with Cocoa are covered here. Unlike the first version of this book it doesn't assume you already knew Objective-C or have had exposure to NextStep. If you're looking for a good book to expose you to Cocoa and Objective-C programming buy this book and work through it all. It's worth it!
This book will also guide you through using the debugger in Project Builder. You'll learn how to use the debugger print-object command and other useful debugging techniques. This book does more than just point out the fact that the debugger exists. It shows you how to apply it usefully.
Another thing I like about this book is the fact that it covers NSString's in more detail than other books of the genre. You'll see examples on how to pull substrings out of NSStrings and use NSRange. You'll also see demonstartions of using NSMutableString as well. Several other books merely mention that NSMutableString exists, but then fail to show what is different between the two.
The excersises at the end of each chapter are very helpful in learning Cocoa Programming too! They're not too difficult, but not too simple either. They'll make you dig and think a bit to find a solution, but not so much that you'll want to pull your hair out and give up. AND If you go happen to get stuck you'll find answers revealed in the back of the book.
This book is for the most part geared towards Mac OS X 10.2, but I did manage to do all of the examples in 10.1.5 (except with the programming example that made use of the Jaguar's Address Book, of course.) This is a bonus, for some of the earlier Cocoa Programming books do not take into account newer versions of Mac OS X and thus are now a bit out of date.
Surprisingly, this book is thicker too, but only because it's now on quality paper. The book actually contains fewer pages (by only a dozen or so) than the original, but Cocoa programming is covered much more thoroughly. There's not much textual fluff or irrelevant screen shots to gobble up pages; --just the right balance of what is needed to cover Cocoa and Objective-C programming for the beginning or semi-intermeddiate programmer.
If you already own the first book don't worry about buying this one and receiving repeat material. These two books are not the same animal (even though the dog on the front cover is the same). They are two totally different creatures with internal organs unique to themselves. In fact, after working through the second edition you might find the first edition more useful; --as you will have gained knowledge from the second version to more completely comprehend chapters in the latter part of the frist version.
One more note: THANK YOU O'REILLY & ASSOCIATES! You're breathing new life into books for the Macintosh! Be it mac-only books (like this Cocoa Programming book) or just the fact that you include MAC OS X specifics in books like "Managing and Using MySQL (2nd Edition)". Myself and I'm sure many others appreciate it. Thanks!
In my opinion, neither book, by itself, provides a complete introduction to Cocoa programming; rather, it is the combination of *both* books that truly provides the introductory material that's fundamental to understanding Cocoa and Objective-C programming. In addition, Mr. Davidson has provided, in my opinion, a more logical and easier to follow progression of topics. Unfortunately, he also fails to provide sufficient depth on some topics after their introduction. Two examples that readily come to mind are the collection classes and memory management. On these two topics, I tip my hat to Mr. Hillegass for providing the better instruction because he: 1.) also explained and gave an example of using enumerators (think C++ interators) to traverse a collection, and 2.) because he gave a very good explanation of where and how to use autoreleased objects in functions.
Overall, I think my biggest compliment about this book is that it maintains a high degree of consistency in the way topics are presented. My biggest complaint is that, in certain areas, the depth of the presentation is simply too shallow. With a little more sustenance, this book could easily become the de facto standard for an introduction to Cocoa programming using Objective-C.