34,333
edits
Changes
no edit summary
{{#pagetitle: Working with Directories in Swift on iOS 10 }}
<seo title="Working with Directories in Swift on iOS 10" titlemode="replace" keywords="ios 10, swift 3, file system, filesystem, directories handling, xcode 8" description="A guide to working with directories within the iOS filesystem."></seo>
<table border="0" cellspacing="0" width="100%"><tr>
<td width="20%">[[An iOS 9 Stack View Tutorial|Previous]]<td align="center">[[iOS 8 App Development Essentials|Table of Contents]]<td width="20%" align="right">[[Working with Files in Swift on iOS 8|Next]]</td>
Since the introduction of iOS 5 the iOS app developer has had two options in terms of storing data. Files and data may now be stored on the file system of the local device or remotely using Apple’s iCloud service. In practice, however, it is most likely that an application will utilize iCloud storage to augment, rather than replace, the use of the local file system so familiarity with both concepts is still a necessity.
The topic of iCloud based storage will be covered in detail beginning with the chapter entitled [[Preparing an iOS 8 App to use iCloud Storage|Preparing an iOS 10 App to use iCloud Storage]]. The goal of this chapter, however, is to provide an overview of how to work with local file system directories from within an iOS 10 application. Topics covered include identifying the application’s document and temporary directories, finding the current working directory, creating, removing and renaming directories and obtaining listings of a directory’s content. Once the topic of directory management has been covered, we will move on to handling files in [[Working with Files in Swift on iOS 108|Working with Files in Swift on iOS 10]].
== The Application Documents Directory ==