diff --git a/mogenerator.h b/mogenerator.h index 003ebb4a..20940152 100644 --- a/mogenerator.h +++ b/mogenerator.h @@ -17,6 +17,11 @@ - (NSArray*)entitiesWithACustomSubclassInConfiguration:(NSString*)configuration_ verbose:(BOOL)verbose_; @end +@interface NSEntityDescription (userInfo) +/// @return Whether or not the entity should be ignored during code generation +- (BOOL)isIgnored; +@end + @interface NSEntityDescription (customBaseClass) - (BOOL)hasCustomClass; - (BOOL)hasSuperentity; @@ -27,7 +32,6 @@ - (NSString*)additionalHeaderFileName; - (void)_processPredicate:(NSPredicate*)predicate_ bindings:(NSMutableArray*)bindings_; - (NSArray*)prettyFetchRequests; -- (BOOL)isIgnored; @end @interface NSAttributeDescription (typing) diff --git a/mogenerator.m b/mogenerator.m index 61ad5d08..64af375a 100644 --- a/mogenerator.m +++ b/mogenerator.m @@ -136,6 +136,15 @@ - (NSArray*)entitiesWithACustomSubclassInConfiguration:(NSString*)configuration_ } @end +@implementation NSEntityDescription (userInfo) +- (BOOL)isIgnored { + NSString *readonlyUserinfoValue = [[self userInfo] objectForKey:kIgnored]; + if (readonlyUserinfoValue != nil) { + return YES; + } + return NO; +} +@end @implementation NSEntityDescription (customBaseClass) - (BOOL)hasCustomBaseCaseImport { @@ -420,13 +429,6 @@ - (NSArray*)prettyFetchRequests { return result; } -- (BOOL)isIgnored { - NSString *readonlyUserinfoValue = [[self userInfo] objectForKey:kIgnored]; - if (readonlyUserinfoValue != nil) { - return YES; - } - return NO; -} @end @implementation NSAttributeDescription (typing)