SlideShare a Scribd company logo
1 of 27
Download to read offline
iOS App Development
                           Lecture 1 - Introduction




Thursday 26 July 12
Acknowledgements

                      • Slides based on the iOS App Development
                        course at UMBC (http://
                        cs491f10.wordpress.com/)
                        and
                        CS 193P at Stanford University (http://
                        www.stanford.edu/class/cs193p/cgi-bin/
                        drupal/)



Thursday 26 July 12
Course Description
                      •   This course provides a study of the design,
                          development and publication of object-oriented
                          applications for iOS platforms (e.g. iPhone, iPod
                          touch & iPad) using the Apple SDK. Students will
                          learn to utilise Objective-C and the various SDK
                          frameworks to build iPhone & iPod touch
                          applications under Mac OS X.

                      •   Prerequisites: RW 214 and RW 344

                      •   Recommended: Competency in C or C++
                          (pointers, memory management, etc.)

Thursday 26 July 12
Course Objectives
                      •   Gain an understanding of the Objective-C language

                      •   Become familiar with the Apple development tools

                      •   Understand and apply design patterns in order to
                          build mobile applications

                      •   Understand and utilise hardware emerging in
                          today’s mobile devices

                      •   Be able to utilise core frameworks of iOS



Thursday 26 July 12
Evaluation


                      • Homework: 20%
                      • Project: 30%


Thursday 26 July 12
Homework


                      1. Create “Your first iOS application” & demo
                         to me: 2.5%
                      2. Write ImageProcessing Application: 17.5%




Thursday 26 July 12
Project
                      • Theme: Mobile for African problems
                      • Functional specification (What): 5%
                       • Compare to existing products (Why)
                      • Task list with milestones and deadlines,
                        mockup: 5%
                      • Final project and demo: 20%
Thursday 26 July 12
Grading Criteria

                      •   Correctness of App

                      •   Appearance of App

                      •   Adherence to Objective-C and iOS coding
                          conventions

                      •   Neatly formatted and indented code

                      •   Well documented header files

                      •   Absence of significant performance issues

                      •   Absence of memory leaks

Thursday 26 July 12
iOS Developer University Program

                      •   Apple has a free iOS University program that
                          provides more benefits than the free registration,
                          including:

                          •   Free on-device development

                          •   Developer forum access

                      •   We will be participating in this program this
                          semester, so if you have an iPhone, iPod touch or
                          iPad, you’ll be able to install and run your apps on-
                          device


Thursday 26 July 12
When / Where did it all
                        start?


Thursday 26 July 12
iOS Architecture



Thursday 26 July 12
OS X Architecture




           Picture from
            Wikipedia



Thursday 26 July 12
iOS         Core OS
                                      Core OS       Power
                      Cocoa Touch     OS X Kernel
                                                    Management
                                      OSX Kernel Power Management
                                                    Keychain
                         Media        Mach 3.0
                                      Mach 3.0       Keychain Access
                                                    Access

                                      BSD
                                       BSD           Certificates
                                                    Certificates
                      Core Services
                                      Sockets
                                       Sockets       File System
                                                    File System
                        Core OS       Security      Bonjour
                                      Security      Bonjour




Thursday 26 July 12
iOS         Core Services
                                      Core OS
                      Cocoa Touch     Collections    Core Location
                                      OSX Kernel Power Management
                         Media        Address Book Net Services
                                      Mach 3.0        Keychain Access
                                      BSD
                                       Networking     Certificates
                                                     Threading
                      Core Services
                                      Sockets
                                       File Access    File System
                                                     Preferences
                        Core OS       Security        Bonjour
                                      SQLite         URL Utilities




Thursday 26 July 12
iOS         Media
                                      Core OS      JPEG, PNG,
                      Cocoa Touch     Core Audio
                                                   TIFF
                                      OSX Kernel Power Management
                         Media        OpenAL       PDF
                                      Mach 3.0      Keychain Access
                                      BSD Mixing Quartz (2D)
                                       Audio      Certificates
                      Core Services
                                      Sockets
                                       Audio       Core System
                                                    File
                                      Recording    Animation
                        Core OS       Security      Bonjour
                                       Video
                                                   OpenGL ES
                                      Playback




Thursday 26 July 12
iOS         Cocoa Touch
                                      Core OS
                      Cocoa Touch     Multi-Touch     Alerts
                                      OSX Kernel Power Management
                         Media        Core Motion Web View
                                      Mach 3.0         Keychain Access
                                       View
                                      BSD
                                       Hierarchy       Certificates
                                                      Map Kit
                      Core Services
                                      Sockets
                                       Localisation    File System
                                                      Image Picker
                        Core OS       Security         Bonjour
                                      Controls        Camera




Thursday 26 July 12
Model View Controller

                                  Controller




                           View                Model




Thursday 26 July 12
A different view




Thursday 26 July 12
Development Stack — Tools




                                Text




                                            Images from Apple
Thursday 26 July 12
Development Stack — Frameworks
                Development Stack — Frameworks



    Foundation Address Book                Map Kit     Core Data




                      UI Kit   Core Animation        OpenGL

                                 Many Others...


Thursday 26 July 12
Development Stack — Language &
               Development Stack — Language & Runtime
               Runtime




                              Objective-C




Thursday 26 July 12
Hello World in
                      Objective-C & Xcode


Thursday 26 July 12
Hello World
        #import <Foundation/Foundation.h>

        int main (int argc, const char * argv[]) {
            NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];

                  // insert code here...
                  NSLog(@"Hello, World!");
        !
                  [pool drain];
                  return 0;
        }




Thursday 26 July 12
Import Statement

                      #import <Foundation/Foundation.h>




        • Exactly like a #include in C/C++, however it ensures that the
          header is only ever included once
        • Foundation/Foundation.h includes many core functions,
          constants, and objects




Thursday 26 July 12
main

                      int main (int argc, const char * argv[]) {
                          ....
                          return 0;
                      }


        • Exactly like a main section in C or C++
          • argc contains the number of command line arguments
          • argv is an array of char pointers (C strings)
          • main returns a value indicating success or failure
            • By convention zero is success, non-zero is failure


Thursday 26 July 12
Pools

            NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
            ...
            [pool drain];



        • These lines allocate an NSAutoreleasePool that is used for
          memory management
        • We’ll cover memory management in some detail in the
          coming classes, but for now we’ll just be sure to include this
          code and put our program between these 2 statements




Thursday 26 July 12
NSLog and @“strings”

                            NSLog(@"Hello, World!");


        • NSLog is a function that’s used for printing a string to the
          console (with some other logging information)
        • Note the goofy @ symbol out in front of the double quoted
          string
          • The @ symbol is used to distinguish the string as an
            Objective-C string (as opposed to a C string)
          • NSLog behaves much like C’s printf function in that it can
            take formatters using % notation and variable number of
            arguments

Thursday 26 July 12

More Related Content

What's hot

2009 CTSA Profiles OpenSocial Poster
2009 CTSA Profiles OpenSocial Poster2009 CTSA Profiles OpenSocial Poster
2009 CTSA Profiles OpenSocial Poster
ericmeeks
 
Network Infrastructure for Academic IC CAD Environments
Network Infrastructure for Academic IC CAD EnvironmentsNetwork Infrastructure for Academic IC CAD Environments
Network Infrastructure for Academic IC CAD Environments
thyandrecardoso
 

What's hot (16)

Android Deep Dive
Android Deep DiveAndroid Deep Dive
Android Deep Dive
 
Updating Your Website to Drupal 7
Updating Your Website to Drupal 7Updating Your Website to Drupal 7
Updating Your Website to Drupal 7
 
2009 CTSA Profiles OpenSocial Poster
2009 CTSA Profiles OpenSocial Poster2009 CTSA Profiles OpenSocial Poster
2009 CTSA Profiles OpenSocial Poster
 
Keat Resume 2012b
Keat Resume 2012bKeat Resume 2012b
Keat Resume 2012b
 
Duncan hallas netbiscuits mobile publishing masterclass
Duncan hallas netbiscuits mobile publishing masterclassDuncan hallas netbiscuits mobile publishing masterclass
Duncan hallas netbiscuits mobile publishing masterclass
 
Squeeze more juice from jenkins
Squeeze more juice from jenkinsSqueeze more juice from jenkins
Squeeze more juice from jenkins
 
EclipseCon2010 - Painless Metamodel Evolution
EclipseCon2010 - Painless Metamodel EvolutionEclipseCon2010 - Painless Metamodel Evolution
EclipseCon2010 - Painless Metamodel Evolution
 
Android For Java Developers
Android For Java DevelopersAndroid For Java Developers
Android For Java Developers
 
Open Android
Open AndroidOpen Android
Open Android
 
Android For Managers Slides
Android For Managers SlidesAndroid For Managers Slides
Android For Managers Slides
 
Network Infrastructure for Academic IC CAD Environments
Network Infrastructure for Academic IC CAD EnvironmentsNetwork Infrastructure for Academic IC CAD Environments
Network Infrastructure for Academic IC CAD Environments
 
Cold Fusion Deck
Cold Fusion DeckCold Fusion Deck
Cold Fusion Deck
 
EclipseConEurope2012 SOA - Models As Operational Documentation
EclipseConEurope2012 SOA - Models As Operational DocumentationEclipseConEurope2012 SOA - Models As Operational Documentation
EclipseConEurope2012 SOA - Models As Operational Documentation
 
6 28-12
6 28-126 28-12
6 28-12
 
Android Internals
Android InternalsAndroid Internals
Android Internals
 
Staying ahead of the multi-core revolution with CDT debug
Staying ahead of the multi-core revolution with CDT debugStaying ahead of the multi-core revolution with CDT debug
Staying ahead of the multi-core revolution with CDT debug
 

Similar to Ios part1

mobile technologies iOS
mobile technologies iOSmobile technologies iOS
mobile technologies iOS
chrisiegers
 
OSWALD: Lessons from and for the Open Hardware Movement
OSWALD: Lessons from and for the Open Hardware MovementOSWALD: Lessons from and for the Open Hardware Movement
OSWALD: Lessons from and for the Open Hardware Movement
OSU Open Source Lab
 
Developing Applications on iOS
Developing Applications on iOSDeveloping Applications on iOS
Developing Applications on iOS
Francisco Ramos
 
Google Android Naver 1212
Google Android Naver 1212Google Android Naver 1212
Google Android Naver 1212
Yoojoo Jang
 
Android platform
Android platformAndroid platform
Android platform
maya_slides
 

Similar to Ios part1 (20)

mobile technologies iOS
mobile technologies iOSmobile technologies iOS
mobile technologies iOS
 
OSWALD: Lessons from and for the Open Hardware Movement
OSWALD: Lessons from and for the Open Hardware MovementOSWALD: Lessons from and for the Open Hardware Movement
OSWALD: Lessons from and for the Open Hardware Movement
 
Apple iOS
Apple iOSApple iOS
Apple iOS
 
201010 SPLASH Tutorial
201010 SPLASH Tutorial201010 SPLASH Tutorial
201010 SPLASH Tutorial
 
What is cocoa
What is cocoaWhat is cocoa
What is cocoa
 
Embarcadero RAD Studio XE3 presentation
Embarcadero RAD Studio XE3 presentationEmbarcadero RAD Studio XE3 presentation
Embarcadero RAD Studio XE3 presentation
 
Developing Applications on iOS
Developing Applications on iOSDeveloping Applications on iOS
Developing Applications on iOS
 
xCode presentation
xCode presentationxCode presentation
xCode presentation
 
200910 - iPhone at OOPSLA
200910 - iPhone at OOPSLA200910 - iPhone at OOPSLA
200910 - iPhone at OOPSLA
 
Lecture1
Lecture1Lecture1
Lecture1
 
iOS Architecture
iOS ArchitectureiOS Architecture
iOS Architecture
 
"Open Source at Microsoft" by Zoli Herczeg @ eLiberatica 2008
"Open Source at Microsoft" by Zoli Herczeg @ eLiberatica 2008"Open Source at Microsoft" by Zoli Herczeg @ eLiberatica 2008
"Open Source at Microsoft" by Zoli Herczeg @ eLiberatica 2008
 
Android & IOS
Android & IOSAndroid & IOS
Android & IOS
 
Xamarin.Mac Seminar
Xamarin.Mac SeminarXamarin.Mac Seminar
Xamarin.Mac Seminar
 
Google Android Naver 1212
Google Android Naver 1212Google Android Naver 1212
Google Android Naver 1212
 
Project Fuji/OpenESB Aquarium Paris
Project Fuji/OpenESB Aquarium ParisProject Fuji/OpenESB Aquarium Paris
Project Fuji/OpenESB Aquarium Paris
 
iOS Development Seminar Keynote
 iOS Development Seminar Keynote iOS Development Seminar Keynote
iOS Development Seminar Keynote
 
Decision Makers Crib: Mobile App Development - Analysis of common frameworks ...
Decision Makers Crib: Mobile App Development - Analysis of common frameworks ...Decision Makers Crib: Mobile App Development - Analysis of common frameworks ...
Decision Makers Crib: Mobile App Development - Analysis of common frameworks ...
 
Android platform
Android platformAndroid platform
Android platform
 
Open source for you - November 2017
Open source for you - November 2017Open source for you - November 2017
Open source for you - November 2017
 

Recently uploaded

Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlFuture Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Peter Udo Diehl
 

Recently uploaded (20)

Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
 
A Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyA Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System Strategy
 
Buy Epson EcoTank L3210 Colour Printer Online.pptx
Buy Epson EcoTank L3210 Colour Printer Online.pptxBuy Epson EcoTank L3210 Colour Printer Online.pptx
Buy Epson EcoTank L3210 Colour Printer Online.pptx
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 
UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1
 
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCustom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
 
IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024
 
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlFuture Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
 
The UX of Automation by AJ King, Senior UX Researcher, Ocado
The UX of Automation by AJ King, Senior UX Researcher, OcadoThe UX of Automation by AJ King, Senior UX Researcher, Ocado
The UX of Automation by AJ King, Senior UX Researcher, Ocado
 
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi IbrahimzadeFree and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
 
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
 
Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024
 
ASRock Industrial FDO Solutions in Action for Industrial Edge AI _ Kenny at A...
ASRock Industrial FDO Solutions in Action for Industrial Edge AI _ Kenny at A...ASRock Industrial FDO Solutions in Action for Industrial Edge AI _ Kenny at A...
ASRock Industrial FDO Solutions in Action for Industrial Edge AI _ Kenny at A...
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
 
ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty Secure
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří Karpíšek
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at Comcast
 
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfIntroduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 

Ios part1

  • 1. iOS App Development Lecture 1 - Introduction Thursday 26 July 12
  • 2. Acknowledgements • Slides based on the iOS App Development course at UMBC (http:// cs491f10.wordpress.com/) and CS 193P at Stanford University (http:// www.stanford.edu/class/cs193p/cgi-bin/ drupal/) Thursday 26 July 12
  • 3. Course Description • This course provides a study of the design, development and publication of object-oriented applications for iOS platforms (e.g. iPhone, iPod touch & iPad) using the Apple SDK. Students will learn to utilise Objective-C and the various SDK frameworks to build iPhone & iPod touch applications under Mac OS X. • Prerequisites: RW 214 and RW 344 • Recommended: Competency in C or C++ (pointers, memory management, etc.) Thursday 26 July 12
  • 4. Course Objectives • Gain an understanding of the Objective-C language • Become familiar with the Apple development tools • Understand and apply design patterns in order to build mobile applications • Understand and utilise hardware emerging in today’s mobile devices • Be able to utilise core frameworks of iOS Thursday 26 July 12
  • 5. Evaluation • Homework: 20% • Project: 30% Thursday 26 July 12
  • 6. Homework 1. Create “Your first iOS application” & demo to me: 2.5% 2. Write ImageProcessing Application: 17.5% Thursday 26 July 12
  • 7. Project • Theme: Mobile for African problems • Functional specification (What): 5% • Compare to existing products (Why) • Task list with milestones and deadlines, mockup: 5% • Final project and demo: 20% Thursday 26 July 12
  • 8. Grading Criteria • Correctness of App • Appearance of App • Adherence to Objective-C and iOS coding conventions • Neatly formatted and indented code • Well documented header files • Absence of significant performance issues • Absence of memory leaks Thursday 26 July 12
  • 9. iOS Developer University Program • Apple has a free iOS University program that provides more benefits than the free registration, including: • Free on-device development • Developer forum access • We will be participating in this program this semester, so if you have an iPhone, iPod touch or iPad, you’ll be able to install and run your apps on- device Thursday 26 July 12
  • 10. When / Where did it all start? Thursday 26 July 12
  • 12. OS X Architecture Picture from Wikipedia Thursday 26 July 12
  • 13. iOS Core OS Core OS Power Cocoa Touch OS X Kernel Management OSX Kernel Power Management Keychain Media Mach 3.0 Mach 3.0 Keychain Access Access BSD BSD Certificates Certificates Core Services Sockets Sockets File System File System Core OS Security Bonjour Security Bonjour Thursday 26 July 12
  • 14. iOS Core Services Core OS Cocoa Touch Collections Core Location OSX Kernel Power Management Media Address Book Net Services Mach 3.0 Keychain Access BSD Networking Certificates Threading Core Services Sockets File Access File System Preferences Core OS Security Bonjour SQLite URL Utilities Thursday 26 July 12
  • 15. iOS Media Core OS JPEG, PNG, Cocoa Touch Core Audio TIFF OSX Kernel Power Management Media OpenAL PDF Mach 3.0 Keychain Access BSD Mixing Quartz (2D) Audio Certificates Core Services Sockets Audio Core System File Recording Animation Core OS Security Bonjour Video OpenGL ES Playback Thursday 26 July 12
  • 16. iOS Cocoa Touch Core OS Cocoa Touch Multi-Touch Alerts OSX Kernel Power Management Media Core Motion Web View Mach 3.0 Keychain Access View BSD Hierarchy Certificates Map Kit Core Services Sockets Localisation File System Image Picker Core OS Security Bonjour Controls Camera Thursday 26 July 12
  • 17. Model View Controller Controller View Model Thursday 26 July 12
  • 19. Development Stack — Tools Text Images from Apple Thursday 26 July 12
  • 20. Development Stack — Frameworks Development Stack — Frameworks Foundation Address Book Map Kit Core Data UI Kit Core Animation OpenGL Many Others... Thursday 26 July 12
  • 21. Development Stack — Language & Development Stack — Language & Runtime Runtime Objective-C Thursday 26 July 12
  • 22. Hello World in Objective-C & Xcode Thursday 26 July 12
  • 23. Hello World #import <Foundation/Foundation.h> int main (int argc, const char * argv[]) { NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; // insert code here... NSLog(@"Hello, World!"); ! [pool drain]; return 0; } Thursday 26 July 12
  • 24. Import Statement #import <Foundation/Foundation.h> • Exactly like a #include in C/C++, however it ensures that the header is only ever included once • Foundation/Foundation.h includes many core functions, constants, and objects Thursday 26 July 12
  • 25. main int main (int argc, const char * argv[]) { .... return 0; } • Exactly like a main section in C or C++ • argc contains the number of command line arguments • argv is an array of char pointers (C strings) • main returns a value indicating success or failure • By convention zero is success, non-zero is failure Thursday 26 July 12
  • 26. Pools NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; ... [pool drain]; • These lines allocate an NSAutoreleasePool that is used for memory management • We’ll cover memory management in some detail in the coming classes, but for now we’ll just be sure to include this code and put our program between these 2 statements Thursday 26 July 12
  • 27. NSLog and @“strings” NSLog(@"Hello, World!"); • NSLog is a function that’s used for printing a string to the console (with some other logging information) • Note the goofy @ symbol out in front of the double quoted string • The @ symbol is used to distinguish the string as an Objective-C string (as opposed to a C string) • NSLog behaves much like C’s printf function in that it can take formatters using % notation and variable number of arguments Thursday 26 July 12