• 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
wrapping my head around NSPredicate
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

wrapping my head around NSPredicate


  • Subject: wrapping my head around NSPredicate
  • From: "Zameer Andani" <email@hidden>
  • Date: Thu, 28 Jul 2005 09:52:34 -0700
  • Thread-topic: Developing for Tiger and Panther;

Can someone perhaps shed some light in how to create a predicate that does an object comparison?

For instance, if I had the following:

@interface classA
{
	NSDictionary *representation;  //initialized with [FirstName ==> "Zameer", LastName ==> "Andani"]
}

@interface classB
{
	NSDictionary *representation; //initialized with [NamePK ==> classA]
}

-(NSPredicate *)predicate
{
	NSMutableString *predicateFormat = [[NSString alloc] init];

	[predicateFormat appendFormat: @"NamePK == ???"];
}

am I allowed to do this, or do I need to fully qualify the string to something like:

"NamePK.FirstName Matches "Zameer"

Zameer

 _______________________________________________
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

  • Prev by Date: Re: Newbie Help understanding Core Data
  • Next by Date: Re: Cocoa and Apple Event
  • Previous by thread: Font error when building a Cocoa automator action
  • Next by thread: RE: wrapping my head around NSPredicate
  • Index(es):
    • Date
    • Thread