Skip to Main Content
Objective-C® For Dummies®
book

Objective-C® For Dummies®

by Neal Goldstein
October 2009
Beginner content levelBeginner
456 pages
8h 59m
English
For Dummies
Content preview from Objective-C® For Dummies®

Chapter 3. The Object in Objective-C

In This Chapter

  • Recognizing the importance of modules

  • Getting a handle on objects

  • Seeing encapsulation and polymorphism in action

  • Refining the idea of "reusable code"

In Chapter 2, you get your first taste of programming (all right, enough with the food), and over the next 15 chapters, I show you everything you need to know to write computer programs. While you may think that's pretty cool, you shouldn't be satisfied with that alone. Your goal shouldn't be to simply be able to write programs using Objective-C; your goal should be to write good programs using Objective-C.

So what makes a good program? Well, a blinding flash of the obvious answer is one that meets the needs of the user. While that is true, it is only part of the answer. What also makes a program good is how easy it is to make changes to it.

I want to use the example I give you in Chapter 1 — a computer program that tracks my expense when I travel. It keeps track of my budget and converts foreign currency charges into dollars.

As I develop this program, I am going to have to make changes to it for three reasons.

  • I'll want to add new functionality. For example, starting out, the program will work with cash and credit card transactions. I'll get that up and running, and then eventually I'll want to be able to add ATM transactions, and also track my hotel and plane reservations. I will want to be able to do this without having to completely rewrite the program. In fact, I would like to be able ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Objective-C

Objective-C

Jiva DeVoe
Cocoa in a Nutshell

Cocoa in a Nutshell

Michael Beam, James Duncan Davidson

Publisher Resources

ISBN: 9780470522752Purchase book