• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: core data design pattern with different model transformations?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: core data design pattern with different model transformations?


  • Subject: Re: core data design pattern with different model transformations?
  • From: Bill Coleman <email@hidden>
  • Date: Sat, 12 Aug 2006 20:04:12 -0400


On Aug 8, 2006, at 5:44 AM, joe OneNinetyTwo wrote:
  I'd like to use Core Data, but I'm confused a bit
about the design approach.    My model has a large
data array (scientific data) that is processed in my
code.   There are many different ways to process the
data, so I have designed different model objects to
manipulate the model data array in different ways.
It wouldn't be that different from an image processing
software with a variety of image filter methods.

I'm new to Cocoa, too, but I would say that if your data are the same, you are just processing it in different ways, then you don't need different model objects.


In Xcode, it's clear how to add attributes and
relationships for the data model, but how would one
incorporation a variety of data transformation methods
(objects that act on the data model)?

Why don't you define an protocol which defines some methods used to process the data, then you can implement several different classes which implement that protocol and thus do different sorts of processing.


The core data model classes would be input to this protocol. (likely you'd just pass an NSArray of data model instances in)

Did that help?


Bill Coleman, AA4LR, PP-ASEL Mail: email@hidden Quote: "Boot, you transistorized tormentor! Boot!" -- Archibald Asparagus, VeggieTales

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >core data design pattern with different model transformations? (From: joe OneNinetyTwo <email@hidden>)

  • Prev by Date: Re: Creating a dictionary who's objects are also linked or indexed?
  • Next by Date: Re: Default value for Date Atttribute in Core Data application
  • Previous by thread: core data design pattern with different model transformations?
  • Next by thread: MacOSX Programming in The Netherlands
  • Index(es):
    • Date
    • Thread