Book Image

Swift Essentials - Second Edition

By : Alex Blewitt
Book Image

Swift Essentials - Second Edition

By: Alex Blewitt

Overview of this book

Swift was considered one of the biggest innovations last year, and certainly with Swift 2 announced at WWDC in 2015, this segment of the developer space will continue to be hot and dominating. This is a fast-paced guide to provide an overview of Swift programming and then walks you through in detail how to write iOS applications. Progress through chapters on custom views, networking, parsing and build a complete application as a Git repository, all by using Swift as the core language
Table of Contents (17 chapters)
Swift Essentials Second Edition
Credits
About the Author
Acknowledgments
About the Reviewer
www.PacktPub.com
Preface
Index

Chapter 3. Creating an iOS Swift App

After the release of Xcode 6 in 2014, it has been possible to build Swift applications for iOS and OS X and submit them to the App Store for publication. This chapter will present both a single view application and a master-detail application, and use these to explain the concepts behind iOS applications, as well as introduce classes in Swift.

This chapter will present the following topics:

  • How iOS applications are structured

  • Single-view iOS applications

  • Creating classes in Swift

  • Protocols and enums in Swift

  • Using XCTest to test Swift code

  • Master-detail iOS applications

  • The AppDelegate and ViewController classes