• 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
NSArrayController vs. fetch
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSArrayController vs. fetch


  • Subject: NSArrayController vs. fetch
  • From: Matteo Rossi <email@hidden>
  • Date: Fri, 6 Oct 2006 13:22:48 +0200

I'm displaying a list of entities in a tableview. I have an outlet to their NSArrayController in my document. If I want to perform some operations on them which is the best choice for retrieving the associated NSArray between

array=[myArrayController arrangedObjects];

and the execution of a fetch request as:

[request setEntity:[NSEntityDescription entityForName:@"myEntity" inManagedObjectContext:moc]];
array=[moc executeFetchRequest:request error:error];


I think the second one is surely updated since synchronizes with the persistent store, while the first might lead to some problems.
Again, is the first approach considered a poor or even wrong implementation ? Which is the fastest, anyway ?
Thank you,
Matteo Rossi



_______________________________________________ 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: NSArrayController vs. fetch
      • From: mmalc crawford <email@hidden>
  • Prev by Date: FetchRequest Template throw exceptions
  • Next by Date: [NSViewAnimation BUG] NSAnimationEaseOut
  • Previous by thread: FetchRequest Template throw exceptions
  • Next by thread: Re: NSArrayController vs. fetch
  • Index(es):
    • Date
    • Thread