Cover by Vandad Nahavandipoor

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

O'Reilly logo

12.0. Introduction

iOS is based on Mac OS X, which itself is based on the UNIX operating system. In iOS, the operating system’s full directory structure is not visible to an app because each app, written by an iOS app developer, lives in its own sandbox. A sandbox environment is exactly what it sounds like: a sanctioned area where only the app that owns the sandbox can access the contents of the folder. Every app has its own sandbox folder and the sandbox folders by default have subfolders that apps can access.

When an iOS app is installed on the device, the folder structure shown in Figure 12-1 will be created for that app by the system.

Depiction of the iOS file system

Figure 12-1. Depiction of the iOS file system

The root folder of every application contains various other folders, which I will explain here:

Name.app

Despite the odd name with the .app extension, this is a folder. The contents of your main bundle will all go in here. For instance, all your app icons, your app binary, your different branding images, fonts, sounds, etc., will all be placed in this folder automatically when iOS installs your app on a device. The name is the product name that you have set for your app. So if your app is called MyApp, the .app folder will be called MyApp.app.

Documents/

This folder is the destination for all user-created content. Content that your app has populated, downloaded, or created should not be stored in this folder. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required