• 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: NSArrayController + KVO + Core Data Question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSArrayController + KVO + Core Data Question


  • Subject: Re: NSArrayController + KVO + Core Data Question
  • From: Ajay Sabhaney <email@hidden>
  • Date: Mon, 23 Aug 2010 00:13:24 -0600

On 2010-08-22, at 11:54 PM, Jerry Krinock wrote:

>
>> it was *necessary*
>
> [emphasis added]
>
>> for me to receive a KVO notification when either a new item was added to the array controller, or removed from the array controller
>
> I'd say that this assumption is the problem.  What you probably *really need* is a notification when relationships change in your *data model*.  I believe the conventional approach would be to *observe your data model* instead of array controller contents.  In other words, "go right to the source".

Jerry, thank you for your response.

Your solution is actually what I am currently doing =)

Like I state in my e-mail, I'm observing the content array of the NSArrayController, and am getting notifications perfectly fine.  I'm just wondering if there's a better way to do all this since I'm losing some of the free functionality provided by NSArrayController + Core Data.  One of the biggest things I'm losing out on is the free loading of documents in to my application.  The NSArrayController does a fetch and populates arrangedObjects, but this brings me back to the original problem of not being able to access the objects that were added to the array controller.

Perhaps I should give up the free functionality that Core Data is providing me and implement this functionality manually?_______________________________________________

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: 
 >NSArrayController + KVO + Core Data Question (From: Ajay Sabhaney <email@hidden>)
 >Re: NSArrayController + KVO + Core Data Question (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Draw String/text in circular path.
  • Next by Date: Re: NSArrayController + KVO + Core Data Question
  • Previous by thread: Re: NSArrayController + KVO + Core Data Question
  • Next by thread: Re: NSArrayController + KVO + Core Data Question
  • Index(es):
    • Date
    • Thread