iOS Persistence and Core Data

Supporting course for the iOS Developer Nanodegree


Need help getting started?


Contents


Course Resources

Downloadable Materials

You can download Supplemental Materials, Lesson Videos and Transcripts from Downloadables (bottom right corner of the Classroom) or from the Dashboard (first option on the navigation bar on the left hand side).

Course Syllabus

Lesson 1: NSUserDefaults

In this lesson, you’ll learn about the memory applications for each state in an app’s life cycle. You’ll also learn to persist an app in the “not running” state using NSUserDefaults and the Documents Directory.

We’ll introduce you to the following iOS classes in this lesson:

  • NSUserDefaults
  • NSFileManager

Lesson 2: NSCoder/NSKeyedArchiver

In this lesson, you’ll learn to persist arrays and dictionaries to the Documents directory, and persist custom structs using a Keyed Archiver.

We’ll introduce you to the following iOS classes in this lesson:

  • NSKeyedArchiver
  • NSKeyedUnarchiver

We’ll also introduce you to the following protocol:

  • NSCoding

Lesson 3: Persistent Objects & Core Data

In this lesson, you’ll be introduced to the Core Data framework, Apple’s favorite framework for the model class. You’ll learn how Core Data manages its stack using a pre-built app, “Favorite Actors.”

We’ll introduce you to the following iOS classes in this lesson:

  • NSManagedObject
  • NSManagedObjectContext
  • NSFetchRequest

Lesson 4: Core Data from Scratch

In this lesson, you’ll learn how to create a Core Data stack from the ground up. You will also learn how to specify relationships between you your Core Data managed objects. By the end, you’ll be proficient enough to describe every element in a Core Data project.

We’ll introduce you to the following iOS classes in this lesson:

  • NSManagedObjectModel
  • NSPersistentStoreCoordinator

Lesson 5: Smart Architecture with Core Data

In this lesson, you’ll learn how Core Data relates to MVC design as Apple envisioned it. You will learn how to architect apps so that controller objects are notified whenever the data stored in Core Data changes, allowing the controllers to keep the views updated in ways that keep your code trim and extensible.

We’ll introduce you to the following iOS classes in this lesson:

  • NSFetchResultsController
  • NSFetchResultsControllerDelegate