Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

teguh123

macrumors member
Original poster
Mar 22, 2011
62
0
I see that Xcode properly add these methods on Business.m

Code:
- (void)addDistrictsObject:(District *)value {    
    NSSet *changedObjects = [[NSSet alloc] initWithObjects:&value count:1];
    [self willChangeValueForKey:@"Districts" withSetMutation:NSKeyValueUnionSetMutation usingObjects:changedObjects];
    [[self primitiveValueForKey:@"Districts"] addObject:value];
    [self didChangeValueForKey:@"Districts" withSetMutation:NSKeyValueUnionSetMutation usingObjects:changedObjects];
    [changedObjects release];
}

Unfortunately xcode do not add

Code:
(void)addDistrictsObject:(District *)value;

On Business.h

Why?

I got compilerwarning when I tried to use function addDistrictsObject

Also I do not want to change either Business.h or Business.m The xdatamodel will still change a lot.

So what should I do?
 
Last edited by a moderator:
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.