Swift Quick Syntax Reference

By Matthew Campbell

Swift Quick Syntax Reference Cover Image

Swift Quick Syntax Reference is a 120-page condensed code and syntax reference to the new Apple Swift programming language, which is the alternative language to Objective-C behind the APIs found in the Apple iOS 8 and Mac OS Yosemite SDKs. It presents the essential Swift syntax in a well-organized format that can be used as a handy reference.

Full Description

  • ISBN13: 978-1-484204-40-5
  • 120 Pages
  • User Level: Beginner to Intermediate
  • Publishing September 30, 2014, but available now as part of the Alpha Program
  • Available eBook Formats: PDF
  • Print Book Price: $19.99
  • eBook Price: $13.99

Related Titles

Full Description

Swift Quick Syntax Reference is a 120-page condensed code and syntax reference to the new Apple Swift programming language, which is the alternative new programming language alongside Objective-C behind the APIs found in the Apple iOS SDK 8 and Mac OS X Yosemite SDK. It presents the essential Swift syntax in a well-organized format that can be used as a handy reference.

You won’t find any technical jargon, bloated samples, drawn out history lessons, or witty stories in this book. What you will find is a language reference that is concise, to the point and highly accessible. The book is packed with useful information and is a must-have for any Swift programmer.

In the Swift Quick Syntax Reference, you will find a concise reference to the Swift language syntax using the new Playgrounds Playgrounds lets you type a line of code and the result appears immediately. This reference is small and handy and ideal for taking with you to your appointments.

What you’ll learn

  • How to use the new Swift programming language and its Playgrounds tool
  • How to declare and print constants, variables
  • What are and how to use numbers, strings, booleans, tuples, optionals, aliases, global and local variables, assertions and more
  • How to use assignment, arithmetic, comparison, ternary conditional, range, and logical operators
  • What are enumerations, arrays, dictionaries, loops, if/switch, control transfer, labeled statements
  • How to do closures in Swift
  • How to define or handle structures, classes, instances, class instance identity, properties, property observers, type properties, type methods
  • How to work with subscripts, inheritance, overriding methods/properties, initialization, type checking/casting, nested types, extensions, delegation, generics and more...

Who this book is for

This book is a quick, handy syntax reference for experienced Objective-C, Mac, and iOS programmers, and a concise, easily-digested introduction for other programmers new to Mac, iOS and of course Swift.

Table of Contents

Table of Contents

1. Hello World

2. Declaring Constants and Variables

3. Printing Variables and Constants

4. Code Comments

5. Numbers

6. Strings

7. Booleans

8. Tuples

9. Optionals

10. Type Aliases

11. Global and Local Variables

12. Assertions

13. Assignment Operators

14. Arithmetic Operators

15. Comparison Operators

16. Ternary Conditional Operator

17. Range Operators

18. Logical Operators

19. Enumeration

20. Arrays

21. Dictionaries

22. Loops

23. If Statements

24. Switch Statements

25. Control Transfer Statements

26. Labeled Statements

27. Functions

28. Nested Functions

29. Closures

30. Defining Structures

31. Defining Classes

32. Using Instances

33. Class Instance Identity Operators

34. Properties

35. Property Observers

36. Type Properties

37. Type Methods

38. Subscripts

39. Inheritance

40. Overriding Methods and Properties

41. Initialization

42. Deinitialization

43. Type Checking and Casting

44. Nested Types

45. Extensions

46. Protocols

47. Delegation

49. Generics

50. Automatic Reference Counting

Errata

Please Login to submit errata.

No errata are currently published