Login required for access
In order to watch this lesson, you'll need to login to the website.
Core Data Singleton Context
Intermediate Training Core Data
In order to view this lesson, you must purchase this course.
Core Data can be a strange beast with all of the moving parts involved setting up our objects. One particular class called NSManagedObjectContext is especially difficult to predict if you have multiple instances of it interacting with Core Data. In today's lesson, we look at what happens when we lose reference to our context and attempt to show data inside of our UI. The solution to maintain our context across our application is to use a <b>Singleton</b> object that lives on forever inside of our application. Inside of this singleton, we keep our <b>NSPersistentContainer</b> property and derive our context using it.

Comments (15)
iosmkarim
5 years ago
Brian Voong
5 years ago
Abdullah Amer II
5 years ago
Brian Voong
5 years ago
Cinquain
5 years ago
Robert Desaeger
5 years ago
Brian Voong
5 years ago
hcri1950
5 years ago
Brian Voong
5 years ago
jdhindsa
5 years ago
jdhindsa
5 years ago
aldo3
5 years ago
Gabriel
6 years ago
Brian Voong
6 years ago
Gabriel
6 years ago
Brian Voong
6 years ago
nerddd
6 years ago
Brian Voong
6 years ago
nerddd
6 years ago
Share App
6 years ago
egarciabalda
6 years ago
diehard98
7 years ago
Sjeijk
6 years ago
Denness
7 years ago
Brian Voong
7 years ago
Denness
7 years ago
edward
7 years ago
Brian Voong
7 years ago
Please contact admin@letsbuildthatapp.com if you have any issues.
HELP & SUPPORT