Slide 1

Slide 1 text

Andri Yadi President, ID-ObjC | CEO, DyCode @andri_yadi | a (at) dycode (dot) com http://andriyadi.me Introduction to iOS Development O ine Class Jasakomer (Special iOS), April 15, 2012

Slide 2

Slide 2 text

about me

Slide 3

Slide 3 text

The rst & largest iOS & OSX developer community in Indonesia ID-ObjectiveC President

Slide 4

Slide 4 text

4 years in a row

Slide 5

Slide 5 text

2011 - now

Slide 6

Slide 6 text

start a company & code for food 9 years in mobile development

Slide 7

Slide 7 text

a movie freak

Slide 8

Slide 8 text

iOS Devices

Slide 9

Slide 9 text

No content

Slide 10

Slide 10 text

21 Start developing iOS apps Today!

Slide 11

Slide 11 text

http://developer.apple.com/ios

Slide 12

Slide 12 text

Xcode iOS Simulator iOS Developer Library

Slide 13

Slide 13 text

Required Stu s

Slide 14

Slide 14 text

No content

Slide 15

Slide 15 text

Latest iOS SDK

Slide 16

Slide 16 text

27 Installing Tools

Slide 17

Slide 17 text

Optional Stu s

Slide 18

Slide 18 text

Actual iOS devices

Slide 19

Slide 19 text

For debugging to device & deployment to AppStore

Slide 20

Slide 20 text

Some development stuffs

Slide 21

Slide 21 text

Objective-C C + OOP ≠ C++

Slide 22

Slide 22 text

A superset of C: • Syntactical convention for de ning classes & method • Syntax for method invocation • Syntax for declaring & synthesizing properties • Static & dynamic typing • Blocks • Extension: protocol & categories Objective-C Advantages: • Dynamic typing: enables to determine the class of an object at runtime • Dynamic binding: allows to determine the method to call at runtime instead of at compile-time • Dynamic loading: allows to add modules of code & other resources at runtime.

Slide 23

Slide 23 text

Classes & Objects

Slide 24

Slide 24 text

Methods & Messaging [aMutableArray insertObject:anObject atIndex:0]; [[self aMutableArray] insertObject:anObject atIndex:0]; [self.aMutableArray insertObject:anObject atIndex:0];

Slide 25

Slide 25 text

Blocks int result = myBlock(4);

Slide 26

Slide 26 text

Protocols & Categories @interface NowPlayingController : UIViewController { } @end Protocol == Interface in other OOP language (Java, C#) @protocol ProfileViewDelegate - (void)profileView:(ProfileView *)profileView doSignInWith: (AuthProviderType)signInType sender:(id)sender; @optional - (void)profileView:(ProfileView *)profileView doSignOut:(id)sender; @end Category, enables to extend a class without subclassing it @interface NSDate (Additions) + (NSDate *)dateFromTimeString:(NSString*)timeString; + (NSDate *)dateWithJSONString:(NSString *)json; - (NSDate *)dateByAddingDays:(NSInteger)numDays; - (NSDate *)dateByAddingHours:(NSInteger)numHours; @end

Slide 27

Slide 27 text

More details: http://bit.ly/AF8EiJ

Slide 28

Slide 28 text

Design Pattern

Slide 29

Slide 29 text

Model-View-Controller design pattern

Slide 30

Slide 30 text

Model-View-Controller design pattern NowPlayingController NowPlayingView NowPlaying

Slide 31

Slide 31 text

No content

Slide 32

Slide 32 text

Reference counting No garbage collector support (yet) Autorelease Pool Memory Management

Slide 33

Slide 33 text

iOS frameworks

Slide 34

Slide 34 text

No content

Slide 35

Slide 35 text

Enable apps to store user documents and key value data Storage Push changes to all user’s computers and devices

Slide 36

Slide 36 text

Easily integrate Tweet Sheet Access system-wide Twitter account from within app Wrap OAuth request & response

Slide 37

Slide 37 text

Memory management becomes compiler’s job Manually enabled in Xcode It’s NOT a garbage collector! Automatic Reference Counting (ARC) No need to deal with retain & release by yourself

Slide 38

Slide 38 text

Layout the app’s work ow & design user interfaces Can be loaded dynamically Storyboard Specify transitions & segues between views

Slide 39

Slide 39 text

Image processing framework nally comes to iOS Advanced features: red-eye reduction, face recognition CoreImage Provides built-in lters: color e ect, distortions, transitions

Slide 40

Slide 40 text

Take advantage of the latest hardware Apple-developed OpenGL ES extensions GLKit: new high-level framework

Slide 41

Slide 41 text

Cocoa Touch Foundation, UIKit, Multi-Touch Gestures

Slide 42

Slide 42 text

Graphics Core Graphics, Core Animation, Core Image, Core Text, OpenGL ES

Slide 43

Slide 43 text

CoreData Database, Object-Relational Mapping, optimized for mobile - > 1 million objects store

Slide 44

Slide 44 text

Audio & Video Media player, Core Audio & OpenAL, iPod library, HTTP Live Streaming

Slide 45

Slide 45 text

Networking Bonjour, Peer to peer, WebKit framework, BSD socket

Slide 46

Slide 46 text

Core Location & MapKit

Slide 47

Slide 47 text

Multitasking New kind of multitasking

Slide 48

Slide 48 text

External display support

Slide 49

Slide 49 text

AirPrint Wireless printing to AirPrint-enabled printers. Hack available

Slide 50

Slide 50 text

Push & Local Notification

Slide 51

Slide 51 text

Game Center Social gaming platform

Slide 52

Slide 52 text

iAd Integrated advertising platform

Slide 53

Slide 53 text

In-App Purchase Payment inside applications

Slide 54

Slide 54 text

Human Interface Design

Slide 55

Slide 55 text

GUI Elements http://www.teehanlax.com/downloads/iOS_5_GUI_iPhone4S.psd.zip

Slide 56

Slide 56 text

Storyboard

Slide 57

Slide 57 text

The app will look like these

Slide 58

Slide 58 text

App Store Submission

Slide 59

Slide 59 text

Finally, on the App Store

Slide 60

Slide 60 text

you app can use this badge!

Slide 61

Slide 61 text

Everything is here: http://developer.apple.com/ios

Slide 62

Slide 62 text

https://developer.apple.com/library/ios/#referencelibrary/ GettingStarted/RoadMapiOS/Introduction/Introduction.html

Slide 63

Slide 63 text

Let’s see some code

Slide 64

Slide 64 text

DYCODE IS HIRING!

Slide 65

Slide 65 text

If you think you’re awesome, either mobile developer guru or still early learner, send your awesome CV to: [email protected]

Slide 66

Slide 66 text

No content