如果我去编辑器>创建管理子类,然后让Xcode生成一个子类,我总是会出错。
我总是在得到这些错误的地方在做错什么事情?
extension Passport { //'Passport' is ambiguous for type lookup in this context
@nonobjc public class func fetchRequest() -> NSFetchRequest<Passport> {
return NSFetchRequest<Passport>(entityName: "Passport") //'Passport' is ambiguous for type lookup in this context
}
@NSManaged public var passportId: String? //@NSManaged only allowed on an instance property or method
@NSManaged public var person: Person? //@NSManaged only allowed on an instance property or method
}
如何解决这些错误或我错了?