Re: Array Key-value Paths
Re: Array Key-value Paths
- Subject: Re: Array Key-value Paths
- From: Allan Odgaard <email@hidden>
- Date: Wed, 26 May 2004 15:54:15 +0200
On 26. May 2004, at 5:50, Sheehan Olver wrote:
[...] what happens when you call:
[self setValue:descriptionArray
forKeyPath:@"array.description"]
It can't call "setDescription:" on anything because "array" is not
populated. I couldn't find a detailed description of key-value paths
in the documentation, unless I just looked in the wrong place.
From NSArray documentation:
- (void)setValue:(id)value forKey:(NSString *)key
Invokes setValue:forKey: on each of the receiver's
items using the specified value and key.
But I am not sure what you refer to above. Is 'array' a key in each
item in descriptionArray? And by "not populated" you mean empty?
Or doesn't it exist? Cause then you'll get a run-time exception.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.