Quantcast
Channel: Core Data – Michael Tsai
Browsing all 217 articles
Browse latest View live

Core Data Book

Florian Kugler and Daniel Eggert: With this book we try to shine a new light on a framework that has been around for a while: We embrace Swift 2 with all its latest language features to write more...

View Article


Core Data Threading Demystified

Marcus Zarra (comments): In the best way, we go back to having one PSC, but we’re going to use the new APIs in iOS 6. We’re going to add a private MOC that talks to that PSC. Then, we’re going to add...

View Article


Pragmatic Core Data

Florian Kugler: Now to answer the ultimate question, how do I get best performance with Core Data? Is the question that I can un-answer in the abstract. I think that your best bet is to look at the...

View Article

Core Data Join Table Records Not Deleted in Ordered Relationship

Tonester: I’m having trouble with a core data many-to-many relationship where both side’s delete rules are set to Nullify. I’m finding when I inspect the SQL database there are records left in the join...

View Article

Core Data Type Safety With Swift

Brian King: Xcode also supports Swift code generation, but I don’t think developers should use it. First off, the amount of code you have to write to use Core Data with Swift is less than with...

View Article


MVC-N: Isolating Network Calls From View Controllers

Marcus Zarra: We have a network controller: it talks to the internet, your local network, or even be a flat file system. It then pushes data into your cache, into your persistence engine. Here comes...

View Article

WWDC 2016 Links

Apple: WWDC Schedule WWDC Videos WWDC 2016 Videos Downloader and PDFs List (via Nevan King) WWDC 2016 Sample Code New Beta Downloads Page What’s New in macOS 10.12 What’s New in iOS 10 What’s New in...

View Article

CloudKit and Map Kit for Gatekeeper Apps

In 2011, I wrote: Would anyone be surprised if future versions of Mac OS X made additional features and APIs available only to App Store apps? In 2012, this came to pass: It’s no longer possible to...

View Article


The Deprecation of iCloud Core Data

In March 2013, I chronicled the problems developers were having with Core Data iCloud syncing. Many concluded that the basic NSPersistentStoreUbiquitousContent design was flawed. Bugs could be fixed,...

View Article


Modern Core Data With Swift

Daniel Eggert: We have used protocol and protocol extensions to make our code more readable. We have also used a few other tricks, but the main gist is that you can create small helpers in your code to...

View Article

Concurrent Core Data, Now Easier Than Ever

Arkadiusz Holko: Our main thread-bounded operations use viewContext. Background work can be performed on a context returned by the factory method newBackgroundContext(). However, usage of...

View Article

SQLITE_ENABLE_SQLLOG

Scott Perry: PSA: SQLite on Sierra/iOS 10 is built with SQLITE_ENABLE_SQLLOG, which makes it easy to create replayable SQL logs SQLite: This file contains experimental code used to record data from...

View Article

Managing Consistency of Immutable Models

Peter Livesey: The first problem we ran into was stability. Core Data is notorious for crashing if one small thing goes wrong. It’s really easy as a developer to introduce race conditions very subtly...

View Article


Working Without a Nib

Jeff Johnson: Four score and minus seventy-two years ago, I brought forth on this internet a new blog post, conceived in levity, and dedicated to the proposition that no nibs are created. Since then,...

View Article

Grand Central Dispatch’s Achilles Heel

Wil Shipley (tweet): I don’t know much about the internals of GCD so I can’t speak with authority, but it seems like this could be solved with a couple of minor changes to sync(): figure out if the...

View Article


Putting Core Data on the Map

Tim Ekl: The Core Data setup was fairly straightforward: I wanted Point to store latitude, longitude, and title, so I added two numeric and one string attribute to the Point entity. […] Right off the...

View Article

Challenges Implementing an iOS Share Extension

Marco Conti: iOS is missing the concept of custom background service that apps and extensions can connect to, something that makes such problems simpler to solve on Android. On iOS we are stuck with...

View Article


WWDC 2017 Links

General: WWDC Schedule WWDC Videos (viewing guide) WWDC 2017 Videos Downloader Beta Downloads Apple Keynotes Podcast High Sierra Download Link Sample Code Downloader What’s New: macOS 10.13 (user...

View Article

Kuery

Kuery: Kuery, a type-safe Core Data query API using Swift 4’s Smart KeyPaths. See also: SE-0161: Smart KeyPaths: Better Key-Value Coding for Swift.

View Article

Surprising Behavior of Non-optional @NSManaged Properties

Arek Holko: A few minutes (or more honestly hours) of debugging later, we notice that the name is an empty string only on instances that were deleted from a context and the context was saved. (Deletion...

View Article
Browsing all 217 articles
Browse latest View live