Building the data object for the MasterProduct entity
To build the data objects (classes) for the MasterProduct entity defined in the data model, follow the given steps:
1. Click any entity in the data model editor and then choose the File | New File option. We get a dialog box to choose the template for the new file.
2. Select Cocoa Touch Classes from under the iPhone OS heading in the left-pane and select the Managed Object Class template. We get a dialog box that prompts for the location of generating the managed object class. Keeping the values as default select the Next button.
3. Check the MasterProduct entity in the dialog box that appears (there is no need for selecting the checkbox for Customer and Product's entity as their managed object classes are already created). We find two checkboxes that are already checked: Generate accessors and Generate Obj-C 2.0 Properties. Keeping the two checkboxes checked, select the Finish button.
We find two files: MasterProduct.h
and MasterProduct...