Package Directories

A Cocoa application’s executable and all associated files are stored in a single directory called a package. Apple’s Finder application identifies package directories and displays them just like single files. From the user’s perspective, applications seem to consist of only one file that can be easily moved or dragged into the desktop’s trash can. The complexity and multitude of files that a developer uses to create an application are hidden from end users. Cocoa’s NSFileWrapper and NSBundle classes for interacting with package directories are described in Chapter 7 and Chapter 8.

NOTE

Apple’s Finder provides a contextual menu accessible by Ctrl-clicking a package. Select Show Package Contents from the menu and Finder will ...

Get Cocoa® Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.