Book description
Ready to build stunning apps for iPhone, iPad, and Apple Watch? This cookbook—completely rewritten with all-new material—provides 90 proven solutions for tackling the latest features in iOS 9 and watchOS 2.0. Written exclusively in Apple’s Swift language, these code-rich recipes show you how to use dynamic user interfaces, interactive maps, multitasking functionality, Apple’s new UI Testing framework, and many other features.
Publisher resources
Table of contents
- Preface
-
Swift 2.0, Xcode 7, and Interface Builder
- 1.1. Handling Errors in Swift
- 1.2. Specifying Preconditions for Methods
- 1.3. Ensuring the Execution of Code Blocks Before Exiting Methods
- 1.4. Checking for API Availability
- 1.5. Categorizing and Downloading Assets to Get Smaller Binaries
- 1.6. Exporting Device-Specific Binaries
- 1.7. Linking Separate Storyboards Together
- 1.8. Adding Multiple Buttons to the Navigation Bar
- 1.9. Optimizing Your Swift Code
- 1.10. Showing the Header View of Your Swift Classes
- 1.11. Creating Your Own Set Types
- 1.12. Conditionally Extending a Type
- 1.13. Building Equality Functionality into Your Own Types
- 1.14. Looping Conditionally Through a Collection
- 1.15. Designing Interactive Interface Objects in Playgrounds
- 1.16. Grouping Switch Statement Cases Together
- 1.17. Bundling and Reading Data in Your Apps
-
Apple Watch
- 2.1. Downloading Files onto the Apple Watch
- 2.2. Noticing Changes in Pairing State Between the iOS and Watch Apps
- 2.3. Transferring Small Pieces of Data to and from the Watch
- 2.4. Transferring Dictionaries in Queues to and from the Watch
- 2.5. Transferring Files to and from the Watch
- 2.6. Communicating Interactively Between iOS and watchOS
- 2.7. Setting Up Apple Watch for Custom Complications
- 2.8. Constructing Small Complications with Text and Images
- 2.9. Displaying Time Offsets in Complications
- 2.10. Displaying Dates in Complications
- 2.11. Displaying Times in Complications
- 2.12. Displaying Time Intervals in Complications
- 2.13. Recording Audio in Your Watch App
- 2.14. Playing Local and Remote Audio and Video in Your Watch App
-
The User Interface
- 3.1. Arranging Your Components Horizontally or Vertically
- 3.2. Customizing Stack Views for Different Screen Sizes
- 3.3. Creating Anchored Constraints in Code
- 3.4. Allowing Users to Enter Text in Response to Local and Remote Notifications
- 3.5. Dealing with Stacked Views in Code
- 3.6. Showing Web Content in Safari View Controller
- 3.7. Laying Out Text-Based Content on Your Views
- 3.8. Improving Touch Rates for Smoother UI Interactions
- 3.9. Supporting Right-to-Left Languages
- 3.10. Associating Keyboard Shortcuts with View Controllers
- 3.11. Recording the Screen and Sharing the Video
- Contacts
- Extensions
- Web and Search
- Multitasking
-
Maps and Location
- 8.1. Requesting the User’s Location a Single Time
- 8.2. Requesting the User’s Location in Background
- 8.3. Customizing the Tint Color of Pins on the Map
- 8.4. Providing Detailed Pin Information with Custom Views
- 8.5. Displaying Traffic, Scale, and Compass Indicators on the Map
- 8.6. Providing an ETA for Transit Transport Type
- 8.7. Launching the iOS Maps App in Transit Mode
- 8.8. Showing Maps in Flyover Mode
- UI Testing
- Core Motion
- Security
- Multimedia
-
UI Dynamics
- 13.1. Adding a Radial Gravity Field to Your UI
- 13.2. Creating a Linear Gravity Field on Your UI
- 13.3. Creating Turbulence Effects with Animations
- 13.4. Adding Animated Noise Effects to Your UI
- 13.5. Creating a Magnetic Effect Between UI Components
- 13.6. Designing a Velocity Field on Your UI
- 13.7. Handling Nonrectangular Views
- Index
Product information
- Title: iOS 9 Swift Programming Cookbook
- Author(s):
- Release date: December 2015
- Publisher(s): O'Reilly Media, Inc.
- ISBN: 9781491936696
You might also like
book
iOS 10 Swift Programming Cookbook
Ready to build truly stunning apps for iPhone, iPad, and Apple Watch? This cookbook—written exclusively in …
book
iOS 11 Swift Programming Cookbook
iOS 11, Swift 4, and Xcode 9 provide many new APIs for iOS developers. With this …
book
iOS 10 Programming for Beginners
Begin your iOS mobile application development journey with this accessible, practical guide About This Book Use …
book
Swift: Developing iOS Applications
Unleash the power of Swift and discover the skills required to build incredible robust iOS applications …