Modern Core Data
summary
Core Data can be modernized by small Swift wrappers that make it more readable and less error‑prone: uses protocol and protocol extensions to map entities to classes and to provide a one-line fetch request with default sort descriptors, replaces fragile string keys with a type-safe KVC pattern (nested enums + compiler-checked keys), supplies a generic ValueTransformer built from two closures, and adds trivial performChanges and managed-object observer helpers — these wrappers work and preserve Core Data’s original behavior.
AI-written summary · about
chapters (10)
- 0:00Introduction
- 2:27Entities and Classes
- 5:16Key Value Coding
- 8:44Better Fetch Request
- 11:14Value Transformer
- 13:56Wrapping Blocks
- 15:46Notifications
- 16:36Observing Notifications
- 20:49Core Data withstructs
- 22:29Conclusion
related talks
53mCoreData in 2015 & Magical Record Meets Swift
26mEffective Core Data with Swift
22mIn defense of Core Data
45mSwiftData as a Replacement for CoreData: Deep Dive
47mExploring Key Practices of Observation and SwiftData in New Application Development
50mWrapping an OO API in a Functional Way
22mThe Great SwiftData Heist
06mThe Type-Safe World of Codable
