iOS Persistence Techniques

  • NSUserDefaults
  • Documents Directory
  • NSCoder
  • Core Data

To really grasp this one needs to understand the app lifecyle in iOS. But, first let’s introduce the AppDelegate

application(_:willFinishLaunchingWithOptions:) and application(_:didFinishLaunchingWithOptions:) are invoked right before the app launches, but are only invoked once for each time the app transitions from not running to active.

applicationDidBecomeActive(_:) is called every time the app becomes active from any state, and may be called multiple times.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Create a free website or blog at WordPress.com.

Up ↑

%d bloggers like this: