Mac Development with Swift
with Daniel Steinberg
Learn how to create native Mac apps from scratch using the new Swift programming language in this hands-on training course taught by an experienced Mac developer.
- Learn how to use the latest Xcode 6 and the new Swift programming language to build Mac apps like the pros.
- Gain hands-on coding experience and get answers to your questions so you can start creating your own Mac apps with confidence.
- Save development time and frustration by focusing exclusively on Mac development for four days with expert guidance.
This 4-day course is designed for experienced programmers who are new to Mac development and who are not yet familiar with the Swift Programming Language. If your group is experienced with Swift, this can also be offered as a 3-day course.
You'll come away from this course ready to create your first Mac app, or improve your existing app. You'll also have a deeper understanding of the principles and patterns behind iOS app development.
What Will I Learn?
How to create native Mac apps from scratch. Through a series of lecture, hands-on exercises, and discussion, you'll learn the fundamentals of building Mac apps. Topics include:
Intro to the Swift Programming Language
Swift is the object-oriented programming language that you use to write Mac (and iOS) apps. You'll learn how to start writing Swift programs using functions, classes, objects, protocols, structs, modules, enumerations, and the fundamental Swift entities and types.
Xcode is the IDE used for Mac (and iOS) development, and it's been redesigned in Xcode 6. Throughout the course you'll get hands-on experience using Xcode and Apple's suite of freely-available developer tools. You'll learn how to use it effectively, and learn various tricks of the trade to work more efficiently.
Good model-view-controller (MVC) design is critical to creating apps that are both maintainable and flexible. You'll learn how to design Mac apps — standard apps as well as document based apps — the Cocoa way.
Views and Their Controllers
Views represent the user interface of your app, and all the dynamic aspects of a view are handled by a view controller. View controllers manage the view that users interact with and are the hub of the model-view-controller (MVC) design. You'll learn how to design views using storyboards and segues, and wire them up to view controllers with outlets and actions. You'll also get an introduction to some of Apple's own pre-built view controllers, which save you tons of work.
Delegates are pervasive throughout Cocoa. They allow you to add custom functionality to your app without subclassing. You'll learn how to use predefined delegates, and create your own, so you can effectively use a vast array of Cocoa classes.
KVC and KVO
Understanding key-value coding (KVC) and key-value observing (KVO) is a fundamental part of programming in Cocoa. KVC and KVO allows you to interact with your objects dynamically and react to changes in state. These two technologies set the stage for bindings.
You'll learn how to automatically link between models, views, and controllers using key-value coding and key-value observing.
Notifications let you keep track of changes in your app. You'll learn how to register, post, and handle notifications in your app to reduce unnecessary coupling. Standard, distributed, and user notifications are covered.
Blocks are a powerful feature in the Swift programming language. You'll learn how to use blocks to simplify your code and specify work to be done in place. Blocks are also useful for concurrency.
Table views are central to many Mac apps. You'll learn how to organize data in tables, insert and delete table data, and navigate between tables using navigation controllers. You'll use the new view-based table cells to create more visually interesting interfaces.
The default set of controls only takes you so far. Set your app apart from the crowd by creating custom views drawn with Core Graphics.
You'll learn how to handle mouse and keyboard events in your app.
Cocoa has a rich set of networking APIs. You'll learn how to interact with web services to extend the reach of your app.
Intro to Core Data
Core Data offers an elegant solution to data modeling and persistence. You'll learn how to get started managing, modeling, querying, and persisting app data using Core Data.
Make your app more responsive by learning to take advantage of Grand Central Dispatch using Operation Queues and Dispatch Queues.
Performance Tuning and Debugging
Learn how to use power tools, including Instruments and the Clang Static Analyzer, to detect memory leaks and profile the performance of your app.
“I learned a lot, and the instructors were both very knowledgeable and able to clearly explain complicated concepts. Well done!”
Who Teaches the Course?
Daniel Steinberg is the author of the books A Swift Kickstart, Developing iOS 7 Apps for iPad and iPhone, iOS Storyboards, and Test Driving iOS Development with Kiwi. He is also the host of the CocoaConf Podcast. He's been teaching iOS development continually since the SDK first appeared in beta, and OS X for many years before. He has presented at Apple's Worldwide Developer Conference, CocoaConf, MacWorld, MacHack, and other Mac developer conferences.
Who's It For?
Teams of five or more experienced programmers. This course will be a good fit for your team if your developers are:
- Experienced programmers with a background in an object-oriented language such as Java, C#, Ruby, or Python. No prior experience with Swift or Objective-C is assumed. However, this course is not a good fit for folks who are new to programming in general.
- New to Mac OS X development and not yet familiar with the Swift Programming Language, or they've started building a Mac app and need help putting all the pieces together.
- If your group is experienced with Swift, this can also be offered as a 3-day course.
“I most liked the instructor's explanations and the ability to ask questions and interact…”
What Do I Need?
Since this course is taught on-site at your location, you'll need the following:
- a training room to comfortably accommodate your team
- a laptop projector and screen
- a whiteboard (or flipchart) with markers
- laptops (or desktops) for each attendee running OS X Mavericks
Prior to the course, we'll provide instructions for installing all the required software, downloading the example code bundle, and other preparatory steps.