- Type Inference
- SWIFT – VARIABLES
- Variable Declaration
- Type Annotations
- Naming Variables
- Printing Variables
- SWIFT – OPTIONALS
- Forced Unwrapping
- Automatic Unwrapping
- Optional Binding
- SWIFT – CONSTANTS
- Constants Declaration
- Type Annotations
- Naming Constants
- Printing Constants
- SWIFT – LITERALS
- Integer Literals
- Floating-point Literals
- String Literals
- Boolean Literals
- SWIFT – OPERATORS
- Arithmetic Operators...........................................................................................................................
- Comparison Operators
- Logical Operators
- Bitwise Operators
- Assignment Operators iv
- Range Operators..................................................................................................................................
- Misc Operators
- Operators Precedence
- SWIFT – DECISION MAKING
- if Statement.........................................................................................................................................
- if-else Statement
- if...else if...else Statement
- Nested If Statements
- Switch Statement
- The? : Operator
- SWIFT – LOOPS
- for-in Loop
- Swift – for Loop
- Swift – while Loop
- Swift – do-while Loop
- Loop Control Statements
- Swift – continue Statement
- Swift – break Statement
- Swift – Fallthrough Statement
- SWIFT – STRINGS
- Create a String
- Empty String
- String Constants
- String Interpolation
- String Concatenation
- String Length v
- String Comparison
- Unicode Strings
- String Functions & Operators
- SWIFT – CHARACTERS
- Empty Character Variables
- Accessing Characters from Strings
- Concatenating Strings with Characters
- SWIFT – ARRAYS
- Creating Arrays
- Accessing Arrays
- Modifying Arrays
- Iterating Over an Array
- Adding Two Arrays
- The count Property
- The empty Property
- SWIFT – DICTIONARIES
- Creating Dictionary
- Accessing Dictionaries
- Modifying Dictionaries
- Remove Key-Value Pairs
- Iterating Over a Dictionary
- Convert to Arrays
- The count Property
- The empty Property
- SWIFT – FUNCTIONS
- Function Definition vi
- Calling a Function
- Parameters and Return Values
- Functions without Parameters
- Functions with Return Values
- Functions without Return Values
- Functions with Optional Return Types
- Functions Local Vs External Parameter Names
- External Parameter Names
- Variadic Parameters
- Constant, Variable, and I/O Parameters
- Function Types & its Usage
- Using Function Types
- Function Types as Parameter Types & Return Types............................................................................
- Nested Functions
- SWIFT – CLOSURES...........................................................................................................
- Expressions in Closures
- Single Expression Implicit Returns
- Known Type Closures
- Declaring Shorthand Argument Names as Closures
- Closures as Operator Functions
- Closures as Trailers
- Capturing Values and Reference Types
- SWIFT – ENUMERATIONS
- Enumeration Functionality
- Enumeration with Switch Statement
- Difference between Associated Values and Raw Values vii
- Enum with Associated Values
- Enum with Raw Values
- SWIFT – STRUCTURES
- Definition of a Structure
- Accessing the Structure and its Properties
- Best Usage Practices of Structures
- SWIFT – CLASSES
- Class Identity Operators
- SWIFT – PROPERTIES
- Stored Properties
- Lazy Stored Property
- Instance Variables
- Computed Properties
- Local and Global Variables
- Type Properties
- Querying and Setting Properties
- SWIFT – METHODS
- Instance Methods
- Local and External Parameter Names
- External Parameter Name with # and _ Symbol
- Self property in Methods
- Modifying Value Types from Instance Methods
- Self Property for Mutating Method
- Type Methods
- SWIFT – SUBSCRIPTS viii
- Subscript Declaration Syntax and its Usage
- Options in Subscript
- SWIFT – INHERITANCE
- Base Class
- Subclass
- Overriding
- Methods Overriding
- Property Overriding
- Overriding Property Observers
- Final Property to prevent Overriding
- SWIFT – INITIALIZATION
- Initializer Role for Stored Properties..................................................................................................
- Setting Property Values by Default
- Parameters Initialization
- Local & External Parameters
- Parameters without External Names
- Optional Property Types
- Modifying Constant Properties During Initialization
- Default Initializers
- Memberwise Initializers for Structure Types
- Initializer Delegation for Value Types
- Class Inheritance and Initialization
- Initializer Inheritance and Overriding
- Failable Initializer
- Failable Initializers for Enumerations
- Failable Initializers for Classes ix
- Overriding a Failable Initializer
- The init! Failable Initializer
- Required Initializers
- SWIFT – DEINITIALIZATION.............................................................................................
- Deinitialization to Deallocate Memory Space
- SWIFT – ARC OVERVIEW
- Functions of ARC
- ARC Program
- ARC Strong Reference Cycles Class Instances
- ARC Weak and Unowned References
- Strong Reference Cycles for Closures
- Weak and Unowned References
- SWIFT – OPTIONAL CHAINING........................................................................................
- Optional Chaining as an Alternative to Forced Unwrapping
- Defining Model Classes for Optional Chaining & Accessing Properties
- Calling Methods Through Optional Chaining
- Accessing Subscripts through Optional Chaining
- Accessing Subscripts of Optional Type
- Linking Multiple Levels of Chaining
- Chaining on Methods with Optional Return Values
- SWIFT – TYPE CASTING
- Defining a Class Hierarchy
- Type Checking
- Downcasting
- Typecasting:Any and Any Object
- AnyObject.......................................................................................................................................... x
- SWIFT – EXTENSIONS
- Computed Properties
- Initializers
- Methods
- Mutating Instance Methods
- Subscripts
- Nested Types
- SWIFT – PROTOCOLS
- Property and Method Requirements
- Mutating Method Requirements
- Initializer Requirements
- Class Implementations of Protocol Initializer Requirements
- Protocols as Types
- Adding Protocol Conformance with an Extension
- Protocol Inheritance
- Class Only Protocols
- Protocol Composition
- Checking for Protocol Conformance
- SWIFT – GENERICS
- Generic Functions: Type Parameters
- Extending a Generic Type
- Type Constraints
- Associated Types
- Where Clauses
- SWIFT – ACCESS CONTROL
- Access Control for Function types xi
- Access Control for Enumeration types
- Access Control for SubClasses
- Access Control for Constants, variables, properties and subscripts
- Getters and Setters
- Access Control for Initializers and Default Initializers
- Access Control for Protocols
- Access Control for Extensions
- Access Control for Generics
- Access Control for Type Aliases
backadmin
(backadmin)
#1