Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8192559
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T04:12:29+00:00 2026-06-07T04:12:29+00:00

I am about to start a new Project for IOS and I will be

  • 0

I am about to start a new Project for IOS and I will be using Core Data as my primary means of storing data for the end user. I have come into a problem in my planning stage of the application as to how I would go about saving, loading and deleting core data objects. Here are the three possible methods which I could think of:

Method 1
Create a universal data object in the Application Delegate that I will retrieve into each view controller using the UISharedApplication method. This would mean that when the application launches, It would create an object with Getters and Setters.
Method 2
Create a data model class (Subclass of NSObject) and initialise that in every view controller. This would mean that every view controller would have to have it’s own NSManagedObjectContext (Application delegate will provide that on launch) that it would pass to the data model class on initialisation. This means that throughout the view controller, it would use it’s own data model class and call methods from that.
Method 3
Have each individual view controller do the saving by itself. e.g. a -(IBAction)didAdd; would have all the code in it to save to the database. This would make it easier to have efficient data calls as it would be able to have a NSFetchResultsController with the correct settings based on the view controller (Batch size, etc.).

I am not sure which way is the best way for me to go and I would appreciate it if any of you could let me know which method is best, or if none are good, what is the best way to do this.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T04:12:31+00:00Added an answer on June 7, 2026 at 4:12 am

    There is also a method number 4, which is similar to your method 1: put your data access code into a model class, and make it a singleton. This is the standard way to share model state among different controllers. Putting all your data management code into that singleton model helps you avoid code duplication.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

About to start a new project in VS2010 which will have a few windows
I'm about to start a new project using node, backbone, underscore, and express among
I'm about to start a new project. The purpose of this project will be
We are about to start a new project. It will be a group of
We are about to start a new project using an existing SQL DB, but
I am about to start a new project. Using VS2010, Silverlight 4, and RIA
I am about to start a new project and am deciding what data access
I'm about to start a new project and this time I will work with
I am about to start a new project in scientific computing, which will run
We are about to start a new project which invovles, at end of process,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.