• 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: Searching a controller's content
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Searching a controller's content


  • Subject: Re: Searching a controller's content
  • From: Camillo Lugaresi <email@hidden>
  • Date: Tue, 24 Jan 2006 14:57:12 +0100

On 22/gen/06, at 14:17, goessly wrote:

I'm looking for a method to obtain an object from a controllers' content programmatically, like this:

id found = [someController getTheObjectThatHas: thisValue forKey:@"theKeyInQuestion"]

Is there such a method or do I have to iterate over the whole content and compare each entry to my search-term?

If the collection is not somehow optimized for searching for values of that key (eg, is it sorted on that key, does it keep an index etc.), a linear search is pretty much what the controller would have to do anyway.


Camillo
_______________________________________________
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


References: 
 >Searching a controller's content (From: goessly <email@hidden>)

  • Prev by Date: Re: invertrect, any cocoa versions suggested?
  • Next by Date: Re: NS .... lex/yacc ?
  • Previous by thread: Re: Searching a controller's content
  • Next by thread: Source location management (was: Subject: Re: Mixing C++ with Objective-C)
  • Index(es):
    • Date
    • Thread