• 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: Entity vs Class mode
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: core data: Entity vs Class mode


  • Subject: Re: core data: Entity vs Class mode
  • From: Rainer Standke <email@hidden>
  • Date: Thu, 17 Dec 2009 09:57:23 -0800

That's helpful, thanks!

Rainer

On Dec 17, 2009, at 9:41 , Quincey Morris wrote:

On Dec 17, 2009, at 09:05, Rainer Standke wrote:

Well, I'm quite new to this, and I am mainly just curious. I am indeed doing both the add: and the prepares content automatically. Seems to work regardless of the mode. Is there anything to read up on this - couldn't find anything specifically on these modes.

There's two points to consider:

1. If you're trying to create Core Data objects, you *must* use entity mode, so that it uses the correct initializer for a NSManagedObject subclass. However, it's certainly possible that NSObjectController in Class mode checks to see if it's really creating a managed object and modifies its own behavior accordingly.

2. In various ways, some NSController and NSObjectController behaviors are just stubs for consistency with important behavior in NSArrayController. In that case it *does* matter which mode you specify.

This is discussed briefly near the start of:

http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/CoreData/Articles/cdBindings.html#/ /apple_ref/doc/uid/TP40004194

It's brief because there isn't much to say. If you're dealing with Core Data, specify an entity name and a managed object context. Otherwise specify a class and no managed object context.



_______________________________________________

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: Entity vs Class mode (From: Rainer Standke <email@hidden>)
 >Re: core data: Entity vs Class mode (From: Quincey Morris <email@hidden>)

  • Prev by Date: Re: Enabling menu items...
  • Next by Date: iCal-like display class (week)?
  • Previous by thread: Re: core data: Entity vs Class mode
  • Next by thread: NSImage support for Windows ico files in 10.4.x?
  • Index(es):
    • Date
    • Thread