Database Reference
In-Depth Information
Figure 20—The main menu xib
name in the Identity inspector in Interface Builder, and change the Label
field in the Document section.
3.
On the Attributes tab of the inspector, change the mode from Class to Entity ,
and change the entity name to Recipe .
4.
Make sure the Prepares Content flag is selected.
5.
On the Bindings tab of the inspector, bind ManagedObjectContext to the
AppDelegate with a model key path of managedObjectContext .
Now that we have the Recipe entity's NSArrayController built, we need to configure
the other two NSArrayController instances, one for the RecipeIngredient entity and
one for the Type entity. The type NSArrayController follows the same steps as our
Recipe entity, but we need to set the entity name to Type so it will populate with
Type objects. Other than that one difference, we follow the previous steps to
complete the type's NSArrayController .
Set the identity of the last NSArrayController , the recipe ingredients' NSArrayController ,
to RecipeIngredient . In the Attributes inspector, choose Entity, and set the entity
name to RecipeIngredient . Set the bindings as before, with one additional change:
on the Bindings tab of the inspector, enable the content set in the controller
content and point it at the recipe's NSArrayController with a controller key of
 
 
 
Search WWH ::




Custom Search