Core Data iOS Essentials

Knowing Core Data gives you the option of creating data-driven iOS apps, and this book is the perfect way to learn as it takes you through the process of creating an actual app with hands-on instructions.

Core Data iOS Essentials

Progressing
B.M.Harwani

Knowing Core Data gives you the option of creating data-driven iOS apps, and this book is the perfect way to learn as it takes you through the process of creating an actual app with hands-on instructions.
$26.99
$44.99
RRP $26.99
RRP $44.99
eBook
Print + eBook
$12.99 p/month

Want this title & more? Subscribe to PacktLib

Enjoy full and instant access to over 2000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.
+ Collection
Free Sample

Book Details

ISBN 139781849690942
Paperback340 pages

About This Book

  • Covers the essential skills you need for working with Core Data in your applications.
  • Particularly focused on developing fast, light weight data-driven iOS applications.
  • Builds a complete example application. Every technique is shown in context.
  • Completely practical with clear, step-by-step instructions.

Who This Book Is For

If you've already explored iOS development and maybe even dabbled with Core Data, this book will set your data-driven application development on a firm footing.

Table of Contents

Chapter 1: Overview
Prerequisite
A brief history
Source code
Shall we begin?
Chapter 2: Understanding Core Data
Core Data
Data Model
Model View Controller (MVC)
Core Data API
Overview of the application: Sales Record System for a Departmental Store
Entity Relationship Diagram
An application output sample
Automatic Master Product Update
Summary
Chapter 3: Understanding Objective-C Protocol and Table View
Protocol
Creating a sample application using a protocol and a delegate
Introduction to Table View
Creating an application to display Table View cells
Adding names to the Table View
Summary
Chapter 4: Designing a Data Model and Building Data Objects for Customers
Creating a new project
Designing the data model
Building data objects for the Customer entity
Understanding code of autogenerated files
Summary
Chapter 5: Creating, Listing, and Deleting Names of Customers
Splitting the task into two modules
Creating a module to save and delete a customer's name
Key value coding (KVC)
Implementing the methods of the NSFetchedResultsControllerDelegate protocol
Running the project
Summary
Chapter 6: Creating, Listing, Displaying, and Deleting Records of Customers
Understanding multiple managed object context
Applying the concept of multiple managed object context in our application
Enhancing our application to save, list, display, and delete customer information
viewDidLoad method
cell AtIndexPath method
didSelectRowAtIndexPath method
addCustomer method
addcustomerController method
Summary
Chapter 7: Updating and Searching Records of Customers
Applying the update feature
Using KVO to know what has been updated
Running the project
Applying search facility
Understanding NSPredicate
Removing the keyboard after selecting a customer's name
Using Predicate Builder for creating a search criterion
Summary
Chapter 8: Entering, Saving, Listing, and Deleting the Records of the Products Sold to the Customers
Adding the product entity to the Data Model
Relationship
Establishing a relationship between the Customer and the Product entities
Building the data object for the Customer and the Product entities
Entering the information of the products sold to the customers
Creating a module to develop an interface to enter the product information
Developing a module to create a menu for manipulating the product information
Creating a module to connect the Product's menu to the rest of the project
Running the project
Summary
Chapter 9: Entering, Displaying, and Deleting the Stock
Adding the MasterProduct entity to the Data Model
Storing the image of the MasterProduct
Building the data object for the MasterProduct entity
Maintaining the MasterProduct information
Summary
Chapter 10: Editing the Stock Information
Module to connect the MasterProduct's menu to the rest of the project
Running the application
Module to modify the information of the master product
Summary
Chapter 11: Displaying the Products for Sale and Updating the Stock
Displaying the products available for sale
Updating the stock
Automatically updating the quantity of the product in the MasterProduct entity
Versioning
Migrations
Summary

What You Will Learn

  • Get a solid grasp of what Core Data is and how it works
  • Build full featured data driven applications for iOS devices
  • Design appropriate data models to fit your app's needs
  • Make your app's data easily searchable
  • Display your data in an attractive, flexible way

In Detail

Core Data is the essential ingredient in data driven iOS apps. It's used for storing, retrieving, and manipulating application data in databases, XML, and binary formats. It's an essential component for iPhone, iPod Touch, and iPad apps.

Core Data Essentials provides a clear, readable guide to the most useful aspects of Core Data. Built around a realistic example app, the book showcases the most important aspects of Core Data development in the context of a complete, functioning app written in Objective C.

The book starts with a tour of how the app works. Then you'll see how to easily display data using the Table View. You'll learn how to develop an appropriate data model that fits the needs of your app, then implement that model as updatable data objects. You'll see how to update data and build relationships between objects and learn how Core Data can work with search, and how to provide your users with friendly data editing features.

Authors

Table of Contents

Chapter 1: Overview
Prerequisite
A brief history
Source code
Shall we begin?
Chapter 2: Understanding Core Data
Core Data
Data Model
Model View Controller (MVC)
Core Data API
Overview of the application: Sales Record System for a Departmental Store
Entity Relationship Diagram
An application output sample
Automatic Master Product Update
Summary
Chapter 3: Understanding Objective-C Protocol and Table View
Protocol
Creating a sample application using a protocol and a delegate
Introduction to Table View
Creating an application to display Table View cells
Adding names to the Table View
Summary
Chapter 4: Designing a Data Model and Building Data Objects for Customers
Creating a new project
Designing the data model
Building data objects for the Customer entity
Understanding code of autogenerated files
Summary
Chapter 5: Creating, Listing, and Deleting Names of Customers
Splitting the task into two modules
Creating a module to save and delete a customer's name
Key value coding (KVC)
Implementing the methods of the NSFetchedResultsControllerDelegate protocol
Running the project
Summary
Chapter 6: Creating, Listing, Displaying, and Deleting Records of Customers
Understanding multiple managed object context
Applying the concept of multiple managed object context in our application
Enhancing our application to save, list, display, and delete customer information
viewDidLoad method
cell AtIndexPath method
didSelectRowAtIndexPath method
addCustomer method
addcustomerController method
Summary
Chapter 7: Updating and Searching Records of Customers
Applying the update feature
Using KVO to know what has been updated
Running the project
Applying search facility
Understanding NSPredicate
Removing the keyboard after selecting a customer's name
Using Predicate Builder for creating a search criterion
Summary
Chapter 8: Entering, Saving, Listing, and Deleting the Records of the Products Sold to the Customers
Adding the product entity to the Data Model
Relationship
Establishing a relationship between the Customer and the Product entities
Building the data object for the Customer and the Product entities
Entering the information of the products sold to the customers
Creating a module to develop an interface to enter the product information
Developing a module to create a menu for manipulating the product information
Creating a module to connect the Product's menu to the rest of the project
Running the project
Summary
Chapter 9: Entering, Displaying, and Deleting the Stock
Adding the MasterProduct entity to the Data Model
Storing the image of the MasterProduct
Building the data object for the MasterProduct entity
Maintaining the MasterProduct information
Summary
Chapter 10: Editing the Stock Information
Module to connect the MasterProduct's menu to the rest of the project
Running the application
Module to modify the information of the master product
Summary
Chapter 11: Displaying the Products for Sale and Updating the Stock
Displaying the products available for sale
Updating the stock
Automatically updating the quantity of the product in the MasterProduct entity
Versioning
Migrations
Summary

Book Details

ISBN 139781849690942
Paperback340 pages
Read More