Chapter 3. An introduction to objects


This chapter covers
  • The concepts of objects, classes, and instances
  • Class hierarchies, inheritance, and polymorphism
  • Foundation Kit
  • The NSString class


In Objective-C the use of object-oriented programming is optional. Because Objective-C is based on a C foundation, it’s possible to use C-style functions (as evidenced by calls to NSLog in the previous chapter), but Objective-C’s full power is unlocked only if you make full use of its object-oriented extensions.

In this chapter we reveal some of the benefits of object-oriented development by covering how the NSString class, provided by Foundation Kit, can improve your productivity while increasing the robustness of any code that interacts with text. ...

Get Objective-C Fundamentals now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.