• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
KVO Oddity
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

KVO Oddity


  • Subject: KVO Oddity
  • From: Chris Pavicich <email@hidden>
  • Date: Thu, 13 May 2004 16:46:23 -0400

Hi List:

I am working on a simple application using KeyValueObserving. And have run into some interesting behaviour
using setKeys:triggerChangeNotificationsForDependentKey: The class I am working with is below.

If I call setKeys:... using @"_attributes" and _attributes is changed a change notification is never sent.
If I call setKeys:... using @"attributes" and _attributes is changes, the notification IS sent.

Perhaps, I don't quite get what's going on, but shouldn't '_attributes' and 'attributes' be interchangeable in this
case?

--CMP


@interface Foo : NSObject
{
NSDictionary *_attributes;
}

- (NSDictionary *)attributes;
- (void) setAttributes:(NSDictionary *)value;

@end
_______________________________________________
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.


  • Follow-Ups:
    • Re: KVO Oddity
      • From: Scott Anguish <email@hidden>
  • Prev by Date: Re: [Slightly OT] PackageMaker question...
  • Next by Date: Re: Is there a regular expression class for Objective C?
  • Previous by thread: Re: Subclassed AppKit vis IB & Designated Initializer
  • Next by thread: Re: KVO Oddity
  • Index(es):
    • Date
    • Thread