Creating Source Code to Implement a Custom Managed Object Class
NSManagedObject subclass for your entity to implement custom methods.
In the project navigator, select the managed object model.
In the Entities table, select the entity or entities for which you want to create an
Choose Editor > Create NSManagedObject subclass.
In the first dialog, select a data model, and click Next.
Then select the entity you want to manage, and click Next
In the next dialog, select the folder where you want the new files to be created and the group where you want the new files to appear in the project navigator.
You must select an entity to enable the Create NSManagedObject subclass menu item.
After you create the files, Xcode adds them to the current target. Xcode also updates the model with the new class names for the entities. Make sure you save the file before you build your project.
If you want to use a different name for a managed object class than its entity name, then you must change the name in several places:
Rename the class in the header and implementation files using the source editor
Change the class name in the utility area
Rename the header and implementation files in the project navigator