Core Data tutorial for iOS -- Introduction

Source: Internet
Author: User
Introduction

Core data is a schema-driven object graph management and persistence framework. Fundamentally, core data helps you to saveModelObjects (in the sense of the Model-View-Controller Design Pattern) to a file and get them back again. This is similar
Archiving (seeArchives and serializations
Programming Guide
), But core data offers much more than that. Amongst other things, it:

Core data is a model-driven object relationship graph management and persistent storage framework. Basically, Core
Data helps you save Model Objects (Model-View-controller design patterns) to a file and retrieve them back. This is similar to archiving (see the archive and serialization Programming Guide), but core
Data provides more. In addition, it also provides:

  • Provides an infrastructure for managing all the changes to your model objects. This gives you automatic support for Undo and redo, and for maintaining reciprocal relationships between objects.

  • Provides an infrastructure for managing all changes to your model objects. This enables your app to automatically support undo and redo operations and maintain the relationships between objects.

  • Allows you to keep just a subset of your model objects in memory at any given time. This is especially important on iOS where conserving memory is critical.

  • Only a subset of Model objects can be saved in the memory at any time. This is especially important for iOS, a system that saves memory.
  • Uses a schema to describe the model objects. You define the principal features of your model classes-including the relationships between them-in a GUI-based editor. This provides a wealth
    Of basic functionality "for free," including setting of default values and attribute value validation.

  • A model is used to describe Model objects. In a GUI-based editor, you can define the main features of model tears-including the relationships between them. This provides a wide range of free features, including default value settings and property value verification.
  • Allows you to maintain disjoint sets of edits of your objects. This is useful if you want to, for example, allow the user to make edits in one view that may be discarded without affecting
    Data displayed in another view.

  • This allows you to keep the non-intersecting sets of editing objects. For example. This function is useful if you want to allow users to perform editing operations in one view and discard the changes in the first view in order not to affect data presentation in the other view.
  • Has an infrastructure for data store versioning and migration. This lets you easily upgrade an old version of the user's file to the current version.

  • Provides basic support for data storage versions and migration. This allows you to easily upgrade user files from the old version to the new version.

Core data is available on iOS 3.0 and later.

Core data is provided only in ios3.0 and later versions.

You shoshould read this document to learn how to use core data on iOS, including:

In iOS, you should read this document to learn how to use core data. Including:

  • The fundamental design patterns and techniques that underlie core data

  • The basic design patterns and technologies are the basis of core data.

  • The basics of using the xcode data modeling tool

  • Basics of using xcode data modeling tools
  • How to create, update, and delete objects managed by core data, and how to Commit Changes to a data store
  • How to create, update, and delete objects managed by core data, and how to submit and change objects to Data Storage

Important: core data is not an entry-level technology. Before starting to use core data, you must understand the basics of IOS application development, including:

Important: core data is not an entry-level technology. Start using core
Before using data, you must understand the basic knowledge of IOS application development, including:

  • How to Use xcode and interface Builder

  • How to Use xcode and interface Builder

  • Fundamental Design Patterns such as Model-View-controller and Delegation

  • Basic design patterns, such as models
    -View-controller and proxy

  • How to Use view controllers, navigation controllers, and table views

  • How to Use view controllers, navigation controllers, and table views

None of these tools and techniques are explained in this tutorial, so that the content can focus on core data itself.
Data itself, this tutorial will not explain these tools and technologies.

Documents you shoshould read to gain adequate experience include:

You should read the following documents to gain sufficient experience:

  • Your
    First iOS app

  • Xcode workspace Guide

  • Cocoa
    Fundamentals Guide

  • View
    Controller Programming Guide for iOS

  • Table
    View programming guide for iOS

Organization
Of this document

This tutorial comprises the following chapters: This tutorial includes the following chapters:

  • "Starting
    Out"

  • "
    Table View Controller"

  • "Managed
    Object and model"

  • "Adding
    Events"

  • "Fetching
    Events"

  • "Deleting
    Events"

  • "Next
    Steps"

The source code for the tutorial is provided inLocationsSample Code.

The source code of this tutorial isThe locations sample code is provided.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.