• 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
Re: KVO and Coredata/Undo Clarification
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: KVO and Coredata/Undo Clarification


  • Subject: Re: KVO and Coredata/Undo Clarification
  • From: mmalcolm crawford <email@hidden>
  • Date: Wed, 15 Mar 2006 18:47:58 -0800


On Mar 15, 2006, at 6:27 PM, email@hidden wrote:

does NSPersistenDocument know to record changes only to a variable if its core data (not a custom ivar) value changed?

It's not clear why you think that NSPersistentDocument would record changes? Changes are recorded by the relevant managed object context's undo manager.


- (void)setValue:(NSData *)value
{
    [self willChangeValueForKey: @"value"];
    [[self valueForKey:@"data"] setValue: value forKey: @"value"];
    [self didChangeValueForKey: @"value"];
}


It's not clear why you're doing this?
The change notification messages are advertising that a property with key-path 'value' is changing. It's not. The property with key-path 'data.value' is changing... The 'data' object should be responsible for sending its own change notification messages.


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


  • Follow-Ups:
    • Re: KVO and Coredata/Undo Clarification
      • From: Andre <email@hidden>
References: 
 >KVO and Coredata/Undo Clarification (From: email@hidden)

  • Prev by Date: KVO and Coredata/Undo Clarification
  • Next by Date: Re: KVO and Coredata/Undo Clarification
  • Previous by thread: KVO and Coredata/Undo Clarification
  • Next by thread: Re: KVO and Coredata/Undo Clarification
  • Index(es):
    • Date
    • Thread