xuzixian

Results 6 comments of xuzixian

请问怎么解决的,谢谢

重新打开,估计是你更换的数据库的路径,然后没有重新初始化各相关model

目前有一取巧方法:在NSObject+Runtime.m文件的+(void)enumerateCls: propertyBlock:的实现代码改成: +(void)enumerateCls:(Class)cls propertyBlock:(void(^)(CoreProperty *p))propertyBlock{ ``` unsigned int numIvars; //成员变量个数 Ivar *vars = class_copyIvarList(cls, &numIvars); //Ivar *vars = class_copyIvarList([UIView class], &numIvars); NSString *key=nil; NSString *type = nil; for(int i =...

问题已解决,出现这个问题的原因是,我临时更改数据库路径,然后,在调用时没有对CoreModel的所有子类建表,解决的办法就是对CoreModel重新建表 #include - (NSArray *)findAllOf:(Class)defaultClass{ int count = objc_getClassList(NULL, 0); if (count