Re: Getting data from NSOutlineView [solved, kind of...]
Re: Getting data from NSOutlineView [solved, kind of...]
- Subject: Re: Getting data from NSOutlineView [solved, kind of...]
- From: mmalcolm crawford <email@hidden>
- Date: Fri, 16 Dec 2005 08:39:13 -0800
On Dec 16, 2005, at 3:44 AM, goessly wrote:
Is it possible that there is no way to access the actual data
managed by Core Data, except within the limited possibilities
provided by bindings? After checking several related topics I'm a
at a complete loss here.
<http://developer.apple.com/documentation/Cocoa/Conceptual/
CoreData/Articles/cdFetching.html>
Thanks for the link! Yet I don't quite get how to use those
fetchRequests... for starters: since I'm working from within
another class, [self ...] won't work, will it? So I'll have to get
the managedObjectContext from my NSTreeController, right?
If you really need to perform a fetch from within a managed object,
then no -- a managed object knows what context it's associated
with. In this case it's not clear why you would be fetching,
though, rather than just following relationships (see <http://
developer.apple.com/documentation/Cocoa/Conceptual/CoreData/Articles/
cdFAQ.html#//apple_ref/doc/uid/TP40001802-242985>).
Another problem: I don't want the _sum_ of managed objects to be
queried for certain matches, I need _certain_ properties for each
entry of my treecontroller, traversed top-down in-order.
Like: Is the first Object a parent-node? Give me its value for he
key "title". Get first Child. Is it a leaf-node? Well, instead of
title hand me the value for the key "priority". And so on. How
would I do this using fetch-requests?
You almost certainly don't -- you follow relationships (see link above).
mmalc
_______________________________________________
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