Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
You haven’t yet arranged for storage of the document’s contents. Before you can attend to that, however, there is one other important feature missing. You have provided no way to create a new Diary Document or to open its window.
You know from Recipe 1 that the Cocoa document-based application template automatically provides a mechanism to create new documents of the application’s primary document type. In Vermont Recipes, the primary document type is the recipes database, controlled by RecipesDocument, RecipesWindowController, and the RecipesWindow nib file, all of which were provided to you by the template under the name MyDocument. The application’s File menu came with a standard New menu item in the MainMenu nib file provided by the template, and you saw in Recipe 1 that you could use it to open new recipes document windows at will. The first new recipes document is automatically opened when you launch the application.