Created
December 16, 2013 18:09
-
-
Save ariok/7991569 to your computer and use it in GitHub Desktop.
Setter method for NSManagedObject subclass properties.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This assumes we have an NSManagedObject with the NSDate* date property | |
- (void)setDate:(NSDate *)date{ | |
[self willChangeValueForKey:@"date"]; | |
[self setPrimitiveValue:date forKey:@"date"]; | |
[self didChangeValueForKey:@"date"]; | |
//If needed | |
//[self updateOtherData]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment