• 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
NSTreeController and Core Data.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTreeController and Core Data.


  • Subject: NSTreeController and Core Data.
  • From: Óscar Morales Vivó <email@hidden>
  • Date: Mon, 4 Jul 2005 00:42:20 -0400

I'm trying to create a small sample application which would have a single entity with a name attribute and a one to many relationship to itself (a parent->children kind of relationship, to-one on the inverse) and to display it using a NSOutlineView.

I understand that to filter the roots for the outline view I just need to filter the controller to parent == nil.

However I'm not sure whether I can somehow use the controller's addChild/InsertChild (now, what was the difference between them?) methods to populate the database, or whether I need to subclass the NSTreeController to override those methods and configure the new objects properly. There doesn't seem to be any way to tell the controller to set the relationships when creating new child objects, but I've seen the frameworks do similar insights before.

I should add that so far I've found the documentation about NSTreeController woefully inadequate (don't worry I don't hold it to anyone ;o). Some sample code and some extra info other than the class documentation would help lots there. If I've missed something please point it my way.

Thanks in advance for any help:

Oscar Morales Vivo.
_______________________________________________
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


  • Follow-Ups:
    • Re: NSTreeController and Core Data.
      • From: mmalcolm crawford <email@hidden>
  • Prev by Date: Re: How to end table cell editing by keyboard (return/enter)?
  • Next by Date: Re: NSTreeController and Core Data.
  • Previous by thread: Re: QTKit quickie
  • Next by thread: Re: NSTreeController and Core Data.
  • Index(es):
    • Date
    • Thread