Re: KVO and arrays
Re: KVO and arrays
- Subject: Re: KVO and arrays
- From: mmalcolm crawford <email@hidden>
- Date: Sun, 2 Jan 2005 23:21:37 -0800
On Jan 2, 2005, at 9:48 PM, kelvSYC wrote:
Suppose I have manual notification of a to-many key foo in my class
(ie. it uses indexed accessors).
This doesn't make sense. Use of indexed accessors typically implies
automatic notification.
I have a method -bar that radically alters foo ("elements" may be
added, removed, or changed programatically). I'm confused whether I
should call (in -bar) -will/didChangeValueForKey or
willChange:valuesAtIndexes:forKey:, and if the latter, what the first
parameter should be.
If you are using manual notifications (i.e. you've overridden
automaticallyNotifiesObserversForKey: to return NO for the relevant
key), then you follow the pattern described here:
<http://developer.apple.com/documentation/Cocoa/Conceptual/
KeyValueObserving/Concepts/AutoVsManual.html>
mmalc
_______________________________________________
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