Re: Retrieving key from NSDictionary in a binding
Re: Retrieving key from NSDictionary in a binding
- Subject: Re: Retrieving key from NSDictionary in a binding
- From: Art Isbell <email@hidden>
- Date: Thu, 2 Sep 2004 13:48:32 -1000
On Sep 2, 2004, at 12:47 PM, Tom Jones wrote:
So I have an NSDictionary where each key is the entityName of a
descendant of EOGenericRecord and each value is an NSArray of the
corresponding entity. Can I bind one of these arrays to a control's
list in WOBuilder?
NSDictionary myDictionary
bind to (NSArray) myDictionary.objectForKey("myEntityName")
It's even better than that: myDictionary.myEntityName.
NSDictionary conforms to the NSKeyValueCoding protocol, so
myDictionary.myEntityName is shorthand for
myDictionary.valueForKey("myEntityName"). However, in WOBuilder,
you'll need to manually enter the dictionary key because there's really
no way that WOBuilder can present the possible dictionary keys.
Aloha,
Art
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.