Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Core Data Crash Course: Learn the Essentials of Core Data
Rating: 4.7 out of 5(8 ratings)
2,296 students

Core Data Crash Course: Learn the Essentials of Core Data

Teaching you the essentials of Core Data.
Created byJuke Moon
Last updated 8/2020
English
English [Auto],

What you'll learn

  • Creating Entities in a Data Model
  • Setting up a Core Data Stack
  • Adding, Deleting, and Saving Objects in Core Data
  • Using NSFetchedResultsController for Displaying Data in UITableView

Course content

1 section8 lectures50m total length
  • Adding a Quote Entity3:21

    Create a new Swift project named quoted, define a core data model with a quote entity and attributes value and author, and set up the core data stack later.

  • Creating a Core Data Stack15:33

    Create a Core Data stack with a singleton Core Data manager and a persistent container. Expose a view context to add, save, fetch, and remove quotes.

  • Setting up a NSFetchedResultsController9:37

    Set up an NSFetchedResultsController for quotes by creating a fetch request, configuring sort descriptors, exposing options, and wiring a core data manager singleton to fetch and display results via delegation.

  • Implementing NSFetchedResultsControllerDelegate8:36

    Learn how to implement NSFetchedResultsControllerDelegate to respond to data changes in a table view, handling section and row inserts, deletes, moves, and updates.

  • Displaying NSFetchedResultsController Object Data in UITableView5:53

    Bind a table view controller to an NSFetchedResultsController to display quotes and authors from Core Data, implement the data source methods, and create helper functions for clean code.

  • Adding and Deleting Core Data Objects5:45

    Learn to add and delete Core Data quotes in a table view, swipe to delete, add quotes with a bar button item, and persist changes with a Core Data manager.

  • Challenge 1: Fetching a Quote0:40
  • Challenge 2: Updating a Quote1:07

Requirements

  • macOS Catalina 10.15.2 or later
  • Xcode 11.4 or above
  • Know how to create an Xcode Project (we have no problem helping if needed)

Description

Data persistence is essential to building successful iOS applications. Core Data is a framework you use to manage the model layer objects in your application. It provides generalized and automated solutions to everyday tasks associated with object life cycle and object graph management, including persistence. Did you know that Core Data typically decreases the amount of code you write to support the model layer by 50 to 70 percent? Whether you're brand new to Core Data or looking for a refresher, this crash course is for you.

This course covers the essentials you need to know to use Core Data to explore more advanced topics effectively. Specifically, we'll build an application with various quotes to inspire you. The course will end by giving you a couple of challenges to solidify your knowledge of Core Data. Ultimately, you will learn everything from creating entities, creating your own Core Data Stack from scratch, utilizing NSFetchedResultsController to display that data inside of a UITableView, and how to add and delete objects in Core Data to see it reflected in your app.

Upon completing this course, you'll be equipped with Core Data's essentials to build apps that support data persistence. See you in the course!

Who this course is for:

  • Beginner iOS Developers curious about Core Data
  • Experienced iOS Developers in need of a refresher on Core Data