Chapter 4

Patterns and Frameworks

In This Chapter

arrow Capturing OO design principles with patterns

arrow Avoiding bad patterns

arrow Reusing and scaffolding for control flow

arrow Applying design patterns in frameworks

Over time and after developers created many OO programs, the software development community built on these programs to create higher-level concepts and techniques. These techniques are called patterns.

About the same time, developers created software frameworks for specific platforms, such as the iOS framework. These frameworks provided libraries of useful functionality that an application developer, such as you, could use in his code. These frameworks also provided application templates that implemented typical flows of control in an application. Because the templates provided most of the generic code, for the most part, you only had to write your app-specific code. Finally, these frameworks used these patterns extensively.

Common Patterns of OO Design

Patterns adhere to the guiding principles of OO design: loose coupling and high cohesion. They use polymorphism by programming to an interface ...

Get Beginning iOS Programming For Dummies 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.