You are previewing iOS 9 SDK Development.
O'Reilly logo
iOS 9 SDK Development

Book Description

iOS 9 gives developers new tools for creating apps for iPhone and iPad, and our new edition of the classic iOS guide is updated to match. By writing clean, expressive, and maintainable Swift code, you'll be able to pull in the iOS 9 SDK's enormous feature set to deliver mobile applications. In this completely revised edition, you'll work through an app's entire lifecycle, from creating the project to publishing on the App Store.

Table of Contents

  1. <span xmlns="" xmlns:epub="" class="toc-secnum">&#160;</span>AcknowledgmentsAcknowledgments
  2. <span xmlns="" xmlns:epub="" class="toc-secnum">&#160;</span>PrefacePreface
    1. About This Edition
    2. So Here’s the Plan
    3. Expectations and Technical Requirements
    4. Online Resources
    5. And Here We Go
  3. Part I. Coding in Swift
    1. <span xmlns="" xmlns:epub="" class="toc-secnum">1. </span>Playing with XcodePlaying with Xcode
      1. Tooling Up with Xcode
      2. Messing Around in a Playground
      3. Getting Serious on the Playground
      4. Digging Into Documentation
      5. What We’ve Learned
    2. <span xmlns="" xmlns:epub="" class="toc-secnum">2. </span>Starting with SwiftStarting with Swift
      1. The Swift Programming Language
      2. Using Variables and Constants
      3. Counting with Numeric Types
      4. Storing Text in Strings
      5. Packaging Data in Collections
      6. Looping and Branching: Control Flow
      7. Maybe It’s There, Maybe It Isn’t: Optionals
      8. What We’ve Learned
    3. <span xmlns="" xmlns:epub="" class="toc-secnum">3. </span>Swift with StyleSwift with Style
      1. Creating Classes
      2. Returning Tuples
      3. Building Lightweight Structures
      4. Listing Possibilities with Enumerations
      5. Handling Errors the Swift 2.0 Way
      6. What We’ve Learned
  4. Part II. Creating the App
    1. <span xmlns="" xmlns:epub="" class="toc-secnum">4. </span>Building User InterfacesBuilding User Interfaces
      1. Our First Project
      2. The Xcode Window
      3. Building Our User Interface
      4. Autolayout
      5. What We’ve Learned
    2. <span xmlns="" xmlns:epub="" class="toc-secnum">5. </span>Connecting the UI to CodeConnecting the UI to Code
      1. Making Connections
      2. Coding the Action
      3. The iOS Programming Stack
      4. Building Views with UIKit
      5. Managing an Object’s Properties
      6. What We’ve Learned
    3. <span xmlns="" xmlns:epub="" class="toc-secnum">6. </span>Testing the AppTesting the App
      1. Unit Tests
      2. How Tests Work in Xcode
      3. Test-Driven Development
      4. Creating Tests
      5. Testing Asynchronously
      6. User Interface Testing
      7. Running and Testing on the Device
      8. What We’ve Learned
    4. <span xmlns="" xmlns:epub="" class="toc-secnum">7. </span>Working with TablesWorking with Tables
      1. Tables on iOS
      2. Table Classes
      3. Creating and Connecting Tables
      4. Filling In the Table
      5. Customizing Table Appearance
      6. Cell Reuse
      7. Custom Table Cells
      8. Pull-to-Refresh
      9. What We’ve Learned
    5. <span xmlns="" xmlns:epub="" class="toc-secnum">8. </span>Managing Time with ClosuresManaging Time with Closures
      1. Setting Up Twitter API Calls
      2. Encapsulating Code in Closures
      3. Using the Twitter Account
      4. Making a Twitter API Request
      5. Parsing the Twitter Response
      6. What We’ve Learned
    6. <span xmlns="" xmlns:epub="" class="toc-secnum">9. </span>Doing Two Things at Once with ClosuresDoing Two Things at Once with Closures
      1. Grand Central Dispatch
      2. Concurrency and UIKit
      3. Do-It-Yourself Concurrency
      4. What We’ve Learned
  5. Part III. Evolving the App
    1. <span xmlns="" xmlns:epub="" class="toc-secnum">10. </span>Managing the App&#8217;s GrowthManaging the App’s Growth
      1. Working with Multiple View Controllers
      2. Refactoring in Xcode
      3. Making the Twitter Code More General Purpose
      4. Trying Out Our Function
      5. What We’ve Learned
    2. <span xmlns="" xmlns:epub="" class="toc-secnum">11. </span>Moving Between View ControllersMoving Between View Controllers
      1. Navigation Controllers
      2. The Navigation Bar
      3. Navigating Between View Controllers
      4. Using the Storyboard Segue
      5. Sharing Data Between View Controllers
      6. Modal Navigation
      7. Exit Segues
      8. What We’ve Learned
    3. <span xmlns="" xmlns:epub="" class="toc-secnum">12. </span>Making the Most of Big ScreensMaking the Most of Big Screens
      1. Split Views on iPad
      2. Split Views on the iPhone
      3. Size Classes and the iPhone 6
      4. What We’ve Learned
    4. <span xmlns="" xmlns:epub="" class="toc-secnum">13. </span>Handling Touch GesturesHandling Touch Gestures
      1. Gesture Recognizers
      2. Pinching and Panning
      3. Affine Transformations
      4. Transforming the Image View
      5. Subview Clipping
      6. What We’ve Learned
    5. <span xmlns="" xmlns:epub="" class="toc-secnum">14. </span>Viewing and Editing PhotosViewing and Editing Photos
      1. Photo Assets and PHAsset Class
      2. Fetching Our Assets
      3. Core Image
      4. What We’ve Learned
  6. Part IV. Beyond the App
    1. <span xmlns="" xmlns:epub="" class="toc-secnum">15. </span>Interacting with iOS and Other AppsInteracting with iOS and Other Apps
      1. The App Life Cycle
      2. Opening via URLs
      3. App Extensions
      4. Creating a Keyboard Extension
      5. Bundling Shared Code in Frameworks
      6. What We’ve Learned
    2. <span xmlns="" xmlns:epub="" class="toc-secnum">16. </span>Fixing the App When It BreaksFixing the App When It Breaks
      1. NSLog(): The First Line of Defense Against Bugs
      2. Breakpoints
      3. Setting Up Your Debugging Environment
      4. What We’ve Learned
    3. <span xmlns="" xmlns:epub="" class="toc-secnum">17. </span>Publishing and Maintaining the AppPublishing and Maintaining the App
      1. Getting with the Program
      2. Preparing the App for Submission
      3. Uploading the App
      4. Testing with TestFlight
      5. Publishing and Beyond
      6. Next Steps
      7. What We’ve Learned