Author: torehalset
Date: Wed Oct 4 12:54:52 2006
New Revision: 452993
URL: http://svn.apache.org/viewvc?view=rev&rev=452993
Log:
* do not autorelease diffs. not important
* log-messages tagged with DEBUG
Modified:
incubator/cayenne/sandbox/CocoaCayenne/CocoaCayenne/CAYObjectContext.m
Modified: incubator/cayenne/sandbox/CocoaCayenne/CocoaCayenne/CAYObjectContext.m
URL:
http://svn.apache.org/viewvc/incubator/cayenne/sandbox/CocoaCayenne/CocoaCayenne/CAYObjectContext.m?view=diff&rev=452993&r1=452992&r2=452993
==============================================================================
--- incubator/cayenne/sandbox/CocoaCayenne/CocoaCayenne/CAYObjectContext.m
(original)
+++ incubator/cayenne/sandbox/CocoaCayenne/CocoaCayenne/CAYObjectContext.m Wed
Oct 4 12:54:52 2006
@@ -42,7 +42,7 @@
self = [super init];
if(self != nil)
{
- diffs = [[NSMutableArray array] retain];
+ diffs = [[NSMutableArray alloc] init];
objectByObjectId = [[NSMutableDictionary alloc] init];
}
return self;
@@ -247,7 +247,7 @@
-(void)registerNewObject:(CAYPersistentObject *)o
{
- NSLog(@"register new object");
+ NSLog(@"DEBUG: register new object");
// TODO: check existing data context?
[o retain];
[o setObjectContext:self];
@@ -282,10 +282,10 @@
NSString *attribute;
while(attribute = [enumerator nextObject])
{
- NSLog(@"check if object has value for %@", attribute);
+ NSLog(@"DEBUG: check if object has value for %@", attribute);
if(![[o valuesRaw] objectForKey:attribute])
{
- NSLog(@"setting %@ to NSNull", attribute);
+ NSLog(@"DEBUG: setting attribute %@ to NSNull", attribute);
[[o valuesRaw] setObject:[NSNull null] forKey:attribute];
}
}