RAPID LEARNING SWIFT
$10.00
Minimum price
$20.00
Suggested price

RAPID LEARNING SWIFT

About the Book

 

Info

SWIFT is object oriented programming language for building applications for OSX and iOS operating systems.

SWIFT home page is at https://developer.apple.com/swift/.

 

Book content

This book is collection of standalone tutorials.

This means that each tutorial contains minimum amount of code needed to explain specific functionality.

This is in contrast to building a single application where each new functionality is added on top of already explained ones.

Each tutorial has minimum amount of supporting text making emphasis on the code example to do the explaining.

 

How to use this book

This book can be used as an introduction to SWIFT language covering all of the basic core functionalities.

In addition book will be updated with more tutorials covering more specific subjects.

Book is also intended as Just In Time Support so that user can learn what it needs when it needs it.

This is why tutorials are standalone and minimalistic focusing only at one problem at the time.

You should however first go through the main features of SWIFT to familiarize yourself with the core concepts.

This can be done by first going through the main chapters as deep as you see fit.

Then later you can come back to explore other more specific chapters as you need them.

About the Author

Ivor Online
Ivor Online

WHY TUTORIALS?

"Things are only as complicated as they are badly explained" 

Proper documentation is essential to avoid struggle and frustration when working with simple things that only seem complicated by not being properly documented and explained. 

 

WHAT KIND OF TUTORIALS?

"Working example is worth thousand words"

Just like the picture is worth thousand words the same goes for the working example. Documentation in the form of working examples is proved to be the fastest and the most effective way of transferring knowledge. Sometimes an example is all you need to get the things done. And if there are some accompanying comments that explain what is going on even better. This approach is used in this book. This results in fast learning and the ability to apply tutorials when you need them in the spirit of Just In Time Support. 

I wish you rapid learning!

www.ivoronline.com

 

 

Table of Contents

1. Introduction

1.1      Create SWIFT Application

1.1.1        Using online compiler

2. Predefined data types and their literals

2.1      Predefined data types

2.1.1        Scalar

2.1.1.1         Nil

2.1.1.2         Bool

2.1.1.3         Int

2.1.1.4         UInt

2.1.1.5         Float

2.1.1.6         Double

2.1.1.7         String

2.1.2        Collection

2.1.2.1         Set

2.1.2.2         Dictionary

2.1.2.3         Array

2.2      Literals

2.2.1        Nil

2.2.2        Boolean

2.2.3        Integer

2.2.3.1         Decimal Notation

2.2.3.2         Binary Notation

2.2.3.3         Octal Notation

2.2.3.4         Hexadecimal Notation

2.2.4        Float

2.2.4.1         Basic Notation

2.2.4.2         Scientific Notation

2.2.5        String

2.2.6        Array

3. Constants, Variables and Optionals

3.1      Constants

3.1.1        Declare

3.1.1.1         Name

3.1.1.2         Data type

3.2      Stored Variables

3.2.1        Declare

3.2.1.1         Name

3.2.1.2         Data type

3.3      Computed Variables

3.3.1        Declare

3.3.1.1         Getter

3.3.1.2         Setter

3.4      Optionals

3.4.1        Declare

3.4.1.1         Name

3.4.1.2         Data type

3.4.1.3         Forced unwrapping

3.4.1.4         Optional binding

3.5      Computed Optionals

3.5.1        Declare

3.5.1.1         Getter

3.5.1.2         Setter

4. Basic syntax

4.1      Comments

4.1.1        Single Line

4.1.2        Multi Line

4.2      Operators

4.2.1        Comparison

4.2.2        Arithmetic

4.2.3        Assignment

4.2.4        Bitwise

4.2.5        Logical

4.3      Statements

4.3.1        Conditional

4.3.1.1         Branching

4.3.1.1.1      if

4.3.1.1.2      if case

4.3.1.1.3      else if

4.3.1.1.4      else if case

4.3.1.1.5      else

4.3.1.1.6      switch...case

4.3.1.1.7      ? :

4.3.1.2         Looping

4.3.1.2.1      for

4.3.1.2.2      for…in

4.3.1.2.3      while

4.3.1.2.4      do...while

4.3.2        Jumping

4.3.2.1         break

4.3.2.2         continue

4.3.2.3         return

4.4      Errors

4.4.1        assert

4.4.2        guard

4.4.3        do...catch

4.5      Type aliases

4.5.1        Declare

4.6      Observers

4.6.1        Declare

4.7      Closures

4.7.1        Declare

5. Creating custom data types

5.1      Classes

5.1.1        Declare data type

5.1.2        Designated Initializer

5.1.3        Convenience Initializer

5.1.4        Deinitializer

5.1.5        Inherit Class

5.1.6        Conform to protocol

5.2      Structures

5.2.1        Declare data type

5.2.2        Initializer

5.2.3        Mutating methods

5.2.4        Conform to protocol

5.3      Enumerators

5.3.1        Simple Enumerator

5.3.1.1         Declare Data Type of Values

5.3.1.1.1      Int

5.3.1.1.2      Float

5.3.1.1.3      String

5.3.1.2         Initializer

5.3.1.3         Reference

5.3.2        Complex Enumerator

5.3.2.1         Declare type

5.3.2.2         Reference

5.3.2.3         Initializer

5.3.2.4         Extract data

5.4      Protocols

5.4.1        Declare data type

5.4.1.1         Property

5.4.1.2         Method

5.5      Functions

5.5.1        Declare

5.5.2        Reference

5.5.3        Name

5.5.4        Scope

5.5.4.1         Global

5.5.4.2         Function

5.5.5        Return

5.5.5.1         Number of values

5.5.5.1.1      None

5.5.5.1.2      Single

5.5.5.1.3      Multiple

5.5.5.2         Types

5.5.5.2.1      Scalar

5.5.5.2.2      Tuple

5.5.5.2.3      Function

5.5.6        Parameters

5.5.6.1         Default values

5.5.6.2         Number of parameters

5.5.6.2.1      Zero

5.5.6.2.2      One

5.5.6.2.3      Multiple

5.5.6.2.4      Variable

5.5.6.3         Names

5.5.6.3.1      No public names declared

5.5.6.3.2      Public names declared

5.5.6.3.3      Public names omitted

5.5.6.4         Modifiers

5.5.6.4.1      Variadic

5.5.6.4.2      Constant

5.5.6.4.3      Variable

5.5.6.4.4      In-Out

5.5.6.5         Types

5.5.6.5.1      Scalar

5.5.6.5.2      Tuple

5.5.6.5.3      Function

5.5.6.5.4      Closure

5.6      Tuples

5.6.1        Declare

5.6.2        Reference

6. Advanced topics

6.1      Properties

6.1.1        Declare

6.1.2        Reference

6.1.2.1         Static field from static method

6.1.2.2         Static field from instance method

6.1.2.3         Static field using class name

6.1.2.4         Instance field from instance method

6.1.2.5         Instance field from object

6.1.2.6         Field using self

6.1.2.7         Parent's fields

6.1.3        Scope Modifiers

6.1.3.1         Public

6.1.3.2         Internal

6.1.3.3         Private

6.1.4        Other Modifiers

6.1.4.1         Static

6.2      Methods

6.2.1        Declare

6.2.2        Reference

6.2.2.1         Static method from static method

6.2.2.2         Static method from instance method

6.2.2.3         Static method using class name

6.2.2.4         Instance method from instance method

6.2.2.5         Instance method from object

6.2.2.6         Method using self

6.2.2.7         Parent's methods

6.2.3        Scope Modifiers

6.2.3.1         Public

6.2.3.2         Internal

6.2.3.3         Private

6.2.4        Other Modifiers

6.2.4.1         Static

6.2.4.2         Final

6.2.5        Predefined

6.2.6        Override

6.3      Extensions

6.3.1        Declare

6.3.2        Add

6.3.2.1         Method

6.3.2.2         Computed property

6.3.2.3         Convenience initializer

6.4      Subscripts

6.4.1        Declare

6.5      Generics

6.5.1        Class

6.5.1.1         Declare

6.5.1.2         Extend

6.5.2        Structure

6.5.2.1         Declare

6.5.2.2         Extend

6.5.3        Enumerator

6.5.3.1         Declare

6.5.4        Function

6.5.4.1         Declare

6.5.5        Constraints

6.5.5.1         Conform to existing protocol

6.5.5.2         Conform to custom protocol

6.6      Custom Operators

6.6.1        Prefix

6.6.2        Postfix

6.6.3        Infix

6.7      Patterns

6.7.1        Wildcard

6.7.2        Identifier

6.7.3        Value-Binding

6.7.4        Tuple

6.7.5        Enumeration Case

7. Tools

7.1      Online compiler

The Leanpub 60 Day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

Now, this is technically risky for us, since you'll have the book or course files either way. But we're so confident in our products and services, and in our authors and readers, that we're happy to offer a full money back guarantee for everything we sell.

You can only find out how good something is by trying it, and because of our 100% money back guarantee there's literally no risk to do so!

So, there's no reason not to click the Add to Cart button, is there?

See full terms...

80% Royalties. Earn $16 on a $20 book.

We pay 80% royalties. That's not a typo: you earn $16 on a $20 sale. If we sell 5000 non-refunded copies of your book or course for $20, you'll earn $80,000.

(Yes, some authors have already earned much more than that on Leanpub.)

In fact, authors have earnedover $13 millionwriting, publishing and selling on Leanpub.

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub