Answer the question
In order to leave comments, you need to log in
How to assign a value to an object property in the willsave method of the NSManagedObject class?
- (void)willSave {
self.flag = true;
}
-(void)willSave {
NSDate *now = [NSDate date];
if (self.modificationDate == nil || [now timeIntervalSinceDate:self.modificationDate] > 1.0) {
self.modificationDate = now;
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question