On Jun 28, 2008, at 10:58 AM, Yoann GINI wrote:
@interface root : NSManagedObject @interface song : root @interface artist : root @interface modification : NSManagedObject
Obj-C classes start with a capital letter, by convention. So -- Root, Song, Artist, and Modification would be standard.
-(void)dataBaseHaveChange:(NSNotification*)notification //I receive here the notification of a CoreData modification{ NSNotification* userInfo = [[notification userInfo] retain];
No need to -retain the userInfo.
NSSet* objectsSet = nil; objectsSet = [userInfo valueForKey:NSInsertedObjectsKey];
You want -objectForKey: -valueForKey: is for key value coding, - objectForKey: is for extracting objects from a dictionary.
Shouldn't cause a problem.
for (NSManagedObject* modEntry in objectsSet) {
Are you sure objectsSet contains any objects?
if ([modEntry isKindOfClass:[root class]]) { //do something } }
b.bum
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]