Book Image

Advanced iOS Development with Swift 4.x [Video]

By : Jonathan Wilson, Benjamin Dordoigne
Book Image

Advanced iOS Development with Swift 4.x [Video]

By: Jonathan Wilson, Benjamin Dordoigne

Overview of this book

Swift is a secure, fast, and interactive programming language. It combines powerful type inference and pattern matching with a modern, lightweight syntax, allowing complex ideas to be expressed in a clear and concise manner. You can start using the new Swift compiler and migrate at your own pace, taking advantage of its new features. This course will provide you with an in-depth knowledge of some of the most sophisticated elements of Swift development, including protocol extensions, error-handling, design patterns, and concurrency, and guide you on how to use and apply them in your own projects. You'll see how even the most challenging design patterns and programming techniques can be used to write cleaner code and build more performant iOS and OS X applications. By the end of this course, you'll have got the hang of effective design patterns and techniques, which means you'll soon be writing better iOS and OS X applications with a new level of composure and control. All the code files and related files are placed on GitHub at this link https://github.com/PacktPublishing/Advanced-iOS-Development-with-Swift-4.x
Table of Contents (7 chapters)
Free Chapter
1
Protocol Extensions and Protocol-Oriented Programming Techniques
2
Error-Handling, Write Crash Resistant Code
4
Advanced Operators: When? Where? and Why?
5
Functions, Beyond the Basics
6
Concurrency, Explore More Complex Concurrent Code
Chapter 3
How to Enhance Your Code with Generics
Content Locked
Section 3
The Where Clause
Walk through a generic implementation of a trading solution. Implement what you have learned in the previous videos and apply the where clause. - Create a generic class to represent Money. Using where clause, we add a sum function - Create a company with a trade function to use the money class to buy goods - Understand why this generic style of programming has allowed us to make an extensible example and how the where clause helped