This book assumes that you already know how to use Swift. If youve worked through any other Swift-based book available from OReilly, like Learning Swift, you should be good to go with this book.
We assume that youre a relatively capable programmer who is happy and confident navigating around OS X, Xcode, and iOS, but we dont assume you know how to program for the Apple Watch (thats what this book is for!)
Organization of This Book
In this book, well be discussing the basics of using Apples WatchKit framework to build watchOS apps. Well be coding in Swift, Apples newest programming language.
Here is a concise breakdown of the material each chapter covers:
reviews what the Apple Watch isand what it isnt. We discuss how and why people might interact with your Apple Watch app, the life cycle of an app, and how it interacts with the users iPhone. We also briefly touch on design contraints and UI controls available for use in your Apple Watch apps.
teaches you how to build an Apple Watch app and its iOS counterpart. We talk about adding controls, working with multiple screens in your app, and sharing data with iOS apps.
discusses glances, the non-interactive component of Apple Watch apps that provides glanceable information to users. We will also demonstrate how to build a simple glance.
covers notifications and the Apple Watch. We discuss creating, presenting, and customizing notifications, as well as how to test notifications and connect them to your interface controller(s).
discusses complications, which let you embed small information displays directly into the watch face to provide timely information to the user.
Conventions Used in This Book
The following typographical conventions are used in this book:
ItalicIndicates new terms, URLs, email addresses, filenames, and file extensions.
Constant width
Used for program listings, as well as within paragraphs to refer to program elements such as variable or function names, databases, data types, environment variables, statements, and keywords.
Constant width bold
Shows commands or other text that should be typed literally by the user.
Constant width italic
Shows text that should be replaced with user-supplied values or by values determined by context.
Tip
This element signifies a tip or suggestion.
Note
This element signifies a general note.
Warning
This element indicates a warning or caution.
Using Code Examples
Supplemental material (code examples, exercises, errata, etc.) is available for download at our site.
This book is here to help you get your job done. In general, if example code is offered with this book, you may use it in your programs and documentation. You do not need to contact us for permission unless youre reproducing a significant portion of the code. For example, writing a program that uses several chunks of code from this book does not require permission. Selling or distributing a CD-ROM of examples from OReilly books does require permission. Answering a question by citing this book and quoting example code does not require permission. Incorporating a significant amount of example code from this book into your products documentation does require permission.
We appreciate, but do not require, attribution. An attribution usually includes the title, author, publisher, and ISBN. For example: Swift Development for the Apple Watch by Jon Manning and Paris Buttfield-Addison (OReilly). Copyright 2016 Secret Lab, 978-1-491-92520-1.
If you feel your use of code examples falls outside fair use or the permission given above, feel free to contact us at .
Finally, wed be remiss if we didnt link to our own blog.
Safari Books Online
Note
Safari Books Online is an on-demand digital library that delivers expert content in both book and video form from the worlds leading authors in technology and business.
Technology professionals, software developers, web designers, and business and creative professionals use Safari Books Online as their primary resource for research, problem solving, learning, and certification training.
Safari Books Online offers a range of plans and pricing for enterprise, government, education, and individuals.
Members have access to thousands of books, training videos, and prepublication manuscripts in one fully searchable database from publishers like OReilly Media, Prentice Hall Professional, Addison-Wesley Professional, Microsoft Press, Sams, Que, Peachpit Press, Focal Press, Cisco Press, John Wiley & Sons, Syngress, Morgan Kaufmann, IBM Redbooks, Packt, Adobe Press, FT Press, Apress, Manning, New Riders, McGraw-Hill, Jones & Bartlett, Course Technology, and hundreds more. For more information about Safari Books Online, please visit us online.