SlideShare a Scribd company logo
Day 2
Recap
Story Boards
Storyboards are the user interface elements of an App
n modern versions of Xcode this is integrated in the program.
Story Boards Explained
edit the file / element your working on. The Bottom allows you to choose
Choose the View Controller
Class that is associated
with this view (MVC)
Choose objects to add to a view such as
UITextField, UIButton or objects such
as a new View.
Delegation
behalf of, or in coordination with, another object when that obje
must fulfil some obligations (delegate methods) usually decla
Examples:
AppDelegate
UITableViewDelegate
Table Views
One of the most commonly used elements is UITable View
Two of Types of UI Table View
Plain Grouped
Table Views
A Table View consists of many parts all of which are
able to be customised.
Table View
Section
Section Header
with Label
Table View Cell
with Label
Table Views
Apple has created a controller for a UITableView
Called UITableViewController and if you subclass it
in your View Controller then it will set this stuff up for you.
Header file (.h)
Subclass UITableViewController
Declare the Delegate and Datasource Protocols
Implementation file (.m)
UITableView
Delegate Methods
Demo
(TableView)
View Controller Lifecycle
viewDidLoad
viewWillAppear
viewDidAppear
viewWillDisappear
viewDidDisappear
viewDidUnload
Demo
(Image View, Web View, Collection View)
Navigation Controller
The Navigation Controller is a very common way to display multiple views
and works with a stack
Navigation Controller
By using the navigation controller iOS creates a container and then
automatically creates the bar at the top with the back button allowing users
to easily navigate. There is also a lot of performance enhancements behind
the scenes too.
To create a navigation stack you can easily do that in the storyboard.
Demo Linking Nav Controller
Persistence
In iOS there are a range of ways to persist data on and off the device.
On Device
• NSUserDefaults (max 300kb) - This is for small amounts of data, usually used for
saving settings / User data in apps
• Plist / Disk - This is for slightly larger data and doesn't really have a limit but can be
low on performance. Mainly used for media on disk.
• Core Data - This is the most common way for storing data and is the iOS internal DB.
It runs on a NO-SQL basis.
• SQL Lite - This is another option for a DB and uses SQL.
Off Device
• Web Service - Third party API’s allow you to easily store data off device and usually
charge based on concurrent requests to the server. Some examples are below.
1. AWS
2. Parse
3. Other 3rd Party
Persistence
File System: Property Lists
- NSArray and NSDictionary can do this
- Can only save supported “plist” types - - NSString
- - NSNumber
- - NSDate
- - NSData
Persistence
File System: Saving Images
- Get resources from the main app bundle (images,
databases, mp4)
Blocks and Multi Threading
One of the main ways in which computers since the 90’s have dealt with
multiple processes is Multi Threading
Multi Threading means that you can run multiple concurrent processes
separately on whats called threads.
Number 1 rule is that all UI should be called on the main thread.
Why use Threads? One use is so that if were pulling data over the network
then we don’t block the UI of the app. If we do it will give a bad experience
and make our user think the app has crashed.
Blocks and Multi Threading
To use threads on iOS we use something called Blocks. Blocks are very
common is iOS since the release of iOS 5.
Blocks
Further info on blocks - http://www.raywenderlich.com/9438/how-to-use-blocks-in-ios-5-tutorial-part-2
What is a block?
- a block of code (i.e a sequence of statements inside {}).
Usually included “in-line” with the calling of a method that is going to
use that block of code.
Example of Block
Blocks and Multi Threading
To dispatch a task to a different Thread we use a C API called ‘Grand
Central Dispatch’ (GCD).
Animations
can easily animate any UI View using core animation. An example of this is b
Categories
Categories allow us to add extra methods to existing classes even if we didn't write them.
Header (.h)
Categories
Interface (.m)
Frameworks and Coca Pods
Frameworks in iOS are collections of code that allow apps to
Examples of Apple Frameworks:
Mapkit
Core Audio
Core Animation
Examples of 3rd Party Frameworks:
Stripe
Facebook
Parse
Twitter
Testing Your App
e simulator then simply build and run and in Xcode and it will la
d to be enrolled in the Apple Developer Program and then gen
Instruments and Other Apps
applications that can be used to find where issues lie in your a
• String with format
• App Coda
• Ray Weinerlich

More Related Content

PDF
Persistence on iOS
PPTX
Building nTier Applications with Entity Framework Services (Part 1)
PPTX
Building nTier Applications with Entity Framework Services (Part 1)
PPTX
Spring framework DAO
PPTX
Entity Framework Database and Code First
PDF
Learn Entity Framework in a day with Code First, Model First and Database First
PPTX
Ef code first
PPTX
Entity Framework V1 and V2
Persistence on iOS
Building nTier Applications with Entity Framework Services (Part 1)
Building nTier Applications with Entity Framework Services (Part 1)
Spring framework DAO
Entity Framework Database and Code First
Learn Entity Framework in a day with Code First, Model First and Database First
Ef code first
Entity Framework V1 and V2

What's hot (20)

PPTX
SQLite database in android
PPTX
Android Database Tutorial
PPTX
Getting started with entity framework
PPTX
Data Handning with Sqlite for Android
PDF
SQLite Database Tutorial In Android
PPTX
Databases in Android Application
PPTX
Introducing Entity Framework 4.0
PPTX
Storage in the Windows Azure Platform - ericnel
PDF
Silverlight difference faqs- 2
PPTX
Spring jdbc dao
PDF
Dicoding Developer Coaching #19: Android | Menyimpan Database Secara Local di...
DOCX
Android database tutorial
PPTX
Entity Framework - Entity Data Model (edm)
PPTX
Database in Android
PPTX
Entity Framework Overview
PPT
DOCX
Learning MVC Part 3 Creating MVC Application with EntityFramework
PPT
SQLITE Android
PPTX
Android MVVM architecture using Kotlin, Dagger2, LiveData, MediatorLiveData
PPTX
A PRESENTATION ON STRUTS & HIBERNATE
SQLite database in android
Android Database Tutorial
Getting started with entity framework
Data Handning with Sqlite for Android
SQLite Database Tutorial In Android
Databases in Android Application
Introducing Entity Framework 4.0
Storage in the Windows Azure Platform - ericnel
Silverlight difference faqs- 2
Spring jdbc dao
Dicoding Developer Coaching #19: Android | Menyimpan Database Secara Local di...
Android database tutorial
Entity Framework - Entity Data Model (edm)
Database in Android
Entity Framework Overview
Learning MVC Part 3 Creating MVC Application with EntityFramework
SQLITE Android
Android MVVM architecture using Kotlin, Dagger2, LiveData, MediatorLiveData
A PRESENTATION ON STRUTS & HIBERNATE
Ad

Viewers also liked (12)

PPTX
iOS course day 1
PDF
Mobile design matters - iOS and Android
PPT
Top 10 trends every iOS app development company should follow
PPTX
Android Training (Storing & Shared Preferences)
PDF
SWIFT & IntelliMATCH
PDF
Architecting iOS Project
PPTX
iOS Coding Best Practices
PDF
Mobile App Design course (iOS & Android)
PDF
A swift introduction to Swift
PPTX
Apple iOS
PDF
Swift Introduction
PDF
Swift Programming Language
iOS course day 1
Mobile design matters - iOS and Android
Top 10 trends every iOS app development company should follow
Android Training (Storing & Shared Preferences)
SWIFT & IntelliMATCH
Architecting iOS Project
iOS Coding Best Practices
Mobile App Design course (iOS & Android)
A swift introduction to Swift
Apple iOS
Swift Introduction
Swift Programming Language
Ad

Similar to iOS Course day 2 (20)

PPTX
LEARNING  iPAD STORYBOARDS IN OBJ-­‐C LESSON 1
PPTX
iOS Development: What's New
PDF
MFF UK - Introduction to iOS
PDF
iOS App Development with Storyboard
PDF
02 objective-c session 2
PDF
FI MUNI 2012 - iOS Basics
PPTX
20 iOS developer interview questions
PPTX
Building your first iOS app using Xamarin
PPTX
iOS for C# Developers - DevConnections Talk
PDF
iPhone dev intro
PDF
Beginning to iPhone development
PDF
iOS storyboard
PPTX
iOS Development (Part 3) - Additional GUI Components
PDF
Session 8 - Xcode 5 and interface builder for iOS 7 application
PDF
MFF UK - Advanced iOS Topics
PDF
Swift
PPT
ios basics
PPTX
Code camp 2011 Getting Started with IOS, Una Daly
PPTX
Basic iOS Training with SWIFT - Part 1
PPT
Synapse india reviews on i phone and android os
LEARNING  iPAD STORYBOARDS IN OBJ-­‐C LESSON 1
iOS Development: What's New
MFF UK - Introduction to iOS
iOS App Development with Storyboard
02 objective-c session 2
FI MUNI 2012 - iOS Basics
20 iOS developer interview questions
Building your first iOS app using Xamarin
iOS for C# Developers - DevConnections Talk
iPhone dev intro
Beginning to iPhone development
iOS storyboard
iOS Development (Part 3) - Additional GUI Components
Session 8 - Xcode 5 and interface builder for iOS 7 application
MFF UK - Advanced iOS Topics
Swift
ios basics
Code camp 2011 Getting Started with IOS, Una Daly
Basic iOS Training with SWIFT - Part 1
Synapse india reviews on i phone and android os

Recently uploaded (20)

PDF
Well-logging-methods_new................
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
DOCX
573137875-Attendance-Management-System-original
PPTX
Geodesy 1.pptx...............................................
PPTX
Welding lecture in detail for understanding
PPTX
CH1 Production IntroductoryConcepts.pptx
PDF
R24 SURVEYING LAB MANUAL for civil enggi
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
UNIT 4 Total Quality Management .pptx
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PPTX
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
PDF
PPT on Performance Review to get promotions
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PDF
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PPTX
Sustainable Sites - Green Building Construction
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PPTX
OOP with Java - Java Introduction (Basics)
Well-logging-methods_new................
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
573137875-Attendance-Management-System-original
Geodesy 1.pptx...............................................
Welding lecture in detail for understanding
CH1 Production IntroductoryConcepts.pptx
R24 SURVEYING LAB MANUAL for civil enggi
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
UNIT 4 Total Quality Management .pptx
Model Code of Practice - Construction Work - 21102022 .pdf
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
UNIT-1 - COAL BASED THERMAL POWER PLANTS
PPT on Performance Review to get promotions
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
Sustainable Sites - Green Building Construction
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
OOP with Java - Java Introduction (Basics)

iOS Course day 2

  • 3. Story Boards Storyboards are the user interface elements of an App n modern versions of Xcode this is integrated in the program.
  • 4. Story Boards Explained edit the file / element your working on. The Bottom allows you to choose Choose the View Controller Class that is associated with this view (MVC) Choose objects to add to a view such as UITextField, UIButton or objects such as a new View.
  • 5. Delegation behalf of, or in coordination with, another object when that obje must fulfil some obligations (delegate methods) usually decla Examples: AppDelegate UITableViewDelegate
  • 6. Table Views One of the most commonly used elements is UITable View Two of Types of UI Table View Plain Grouped
  • 7. Table Views A Table View consists of many parts all of which are able to be customised. Table View Section Section Header with Label Table View Cell with Label
  • 8. Table Views Apple has created a controller for a UITableView Called UITableViewController and if you subclass it in your View Controller then it will set this stuff up for you. Header file (.h) Subclass UITableViewController Declare the Delegate and Datasource Protocols Implementation file (.m) UITableView Delegate Methods
  • 11. Demo (Image View, Web View, Collection View)
  • 12. Navigation Controller The Navigation Controller is a very common way to display multiple views and works with a stack
  • 13. Navigation Controller By using the navigation controller iOS creates a container and then automatically creates the bar at the top with the back button allowing users to easily navigate. There is also a lot of performance enhancements behind the scenes too. To create a navigation stack you can easily do that in the storyboard. Demo Linking Nav Controller
  • 14. Persistence In iOS there are a range of ways to persist data on and off the device. On Device • NSUserDefaults (max 300kb) - This is for small amounts of data, usually used for saving settings / User data in apps • Plist / Disk - This is for slightly larger data and doesn't really have a limit but can be low on performance. Mainly used for media on disk. • Core Data - This is the most common way for storing data and is the iOS internal DB. It runs on a NO-SQL basis. • SQL Lite - This is another option for a DB and uses SQL. Off Device • Web Service - Third party API’s allow you to easily store data off device and usually charge based on concurrent requests to the server. Some examples are below. 1. AWS 2. Parse 3. Other 3rd Party
  • 15. Persistence File System: Property Lists - NSArray and NSDictionary can do this - Can only save supported “plist” types - - NSString - - NSNumber - - NSDate - - NSData
  • 16. Persistence File System: Saving Images - Get resources from the main app bundle (images, databases, mp4)
  • 17. Blocks and Multi Threading One of the main ways in which computers since the 90’s have dealt with multiple processes is Multi Threading Multi Threading means that you can run multiple concurrent processes separately on whats called threads. Number 1 rule is that all UI should be called on the main thread. Why use Threads? One use is so that if were pulling data over the network then we don’t block the UI of the app. If we do it will give a bad experience and make our user think the app has crashed.
  • 18. Blocks and Multi Threading To use threads on iOS we use something called Blocks. Blocks are very common is iOS since the release of iOS 5. Blocks Further info on blocks - http://www.raywenderlich.com/9438/how-to-use-blocks-in-ios-5-tutorial-part-2 What is a block? - a block of code (i.e a sequence of statements inside {}). Usually included “in-line” with the calling of a method that is going to use that block of code. Example of Block
  • 19. Blocks and Multi Threading To dispatch a task to a different Thread we use a C API called ‘Grand Central Dispatch’ (GCD).
  • 20. Animations can easily animate any UI View using core animation. An example of this is b
  • 21. Categories Categories allow us to add extra methods to existing classes even if we didn't write them. Header (.h)
  • 23. Frameworks and Coca Pods Frameworks in iOS are collections of code that allow apps to Examples of Apple Frameworks: Mapkit Core Audio Core Animation Examples of 3rd Party Frameworks: Stripe Facebook Parse Twitter
  • 24. Testing Your App e simulator then simply build and run and in Xcode and it will la d to be enrolled in the Apple Developer Program and then gen
  • 25. Instruments and Other Apps applications that can be used to find where issues lie in your a
  • 26. • String with format • App Coda • Ray Weinerlich