I have a problem with core data in IOS 8. Whenever I want to use the insertNewObjectForEntityForName
method, I get the
Class not found,
When using Swift the error could still appear also if the source file is included in the Build Phases > Compile Sources the error
unable to load class named '...' for entity '...'. class not found, using default nsmanagedobject instead.
To solve this you could prefix the specific model class in the model inspector (here with MyApp). See also the documentation.
Our you can add objc(Person)
before your swift class declaration
@objc(Person)
class Person: NSManagedObject {
...
}