Can a model key path binding access a super class property
Can a model key path binding access a super class property
- Subject: Can a model key path binding access a super class property
- From: Grant Christensen <email@hidden>
- Date: Sun, 17 Jan 2010 23:53:51 +1000
Hi all,
I have two classes, one defining a few base properties, and another more specific class inheriting from it. Example below:
@interface BBSBaseClass : NSObject {
NSString *aValue;
}
@property (readwrite, copy) NSString *aValue;
@end
@interface BBSMoreSpecific : BBSBaseClass {
NSString *anotherValue;
}
@property (readwrite, assign) NSString *anotherValue;
@end
In my window I have a NSTableView that is using an array controller to get access to my data. The array controller is bound to an array of BBSMoreSpecific classes.
The problem I am having is that all of my columns bound to the fields in the BBSMoreSpecific class show their data, but those bound to those in the base class do not. I am using a simple model key path of just the name of the ivar, so aValue and anotherValue.
Can the bindings access the base class or can they only access values in the class the array controller is directly connected to?
regards,
---
Grant Christensen
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden