• 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: Instantiating linked entities
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core Data: Instantiating linked entities


  • Subject: Re: Core Data: Instantiating linked entities
  • From: Chris Hanson <email@hidden>
  • Date: Mon, 01 Sep 2008 18:19:12 -0700

On Sep 1, 2008, at 3:15 AM, Renaud Céroce wrote:

I read somewhere in Apple's doc that an object was responsible for
instantiating the other objects it depends on. It don't find it logical
because I've already defined the relationships in the xcdatamodel

The reason it is logical is that your data model declares the relationships that may exist between any Shape, any Color, and any Rect. Not just between a specific Shape, a specific Color, and a specific Rect.


Furthermore, each of your entities is a peer in your data model, not subordinate to some main entity. Thus you might actually want to set up your relationships such that the relationship from Color to Shape is to-many; that would let you have one Color that's shared among multiple Shapes.

  -- Chris

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Core Data: Instantiating linked entities (From: Renaud Céroce <email@hidden>)

  • Prev by Date: Re: how to delete the current user's directory?
  • Next by Date: basic Core Data scaling question
  • Previous by thread: Re: Core Data: Instantiating linked entities
  • Next by thread: re:Core Data: Instantiating linked entities
  • Index(es):
    • Date
    • Thread