FROM : David Bainbridge
DATE : Thu Jan 03 18:34:29 2008
I have a data structure that basically represents an XML file. The
top level is an NSDictionary and can have values which are
NSDictionaries themselves and/or NSArrays.
As an example I need to bind to a table column the results you would
get from the following statement:
[[myObject properties] valueForKeyPath:@"employees.name"]
properties is an NSMutableDictionary; the key "employees" is an
NSArray; each object in the NSArray is an NSDictionary which in this
case has a key "name".
The valueForKeyPath statement above returns an array of names as I
expected but I would like to bind that (given myObject) to a table
column within IB.
I know I can set an ivar to the valueForKeyPath result but I was
hoping to simply specify this in IB without code.
DATE : Thu Jan 03 18:34:29 2008
I have a data structure that basically represents an XML file. The
top level is an NSDictionary and can have values which are
NSDictionaries themselves and/or NSArrays.
As an example I need to bind to a table column the results you would
get from the following statement:
[[myObject properties] valueForKeyPath:@"employees.name"]
properties is an NSMutableDictionary; the key "employees" is an
NSArray; each object in the NSArray is an NSDictionary which in this
case has a key "name".
The valueForKeyPath statement above returns an array of names as I
expected but I would like to bind that (given myObject) to a table
column within IB.
I know I can set an ivar to the valueForKeyPath result but I was
hoping to simply specify this in IB without code.
| Related mails | Author | Date |
|---|---|---|
| David Bainbridge | Jan 3, 18:34 | |
| Keary Suska | Jan 3, 21:13 |






Cocoa mail archive

