development · cocoaheads ann arbor users group for ios and mac os x developers ... distribution in...

43
Beginning Christopher M. Judd Development iOS Sunday, October 24, 2010

Upload: others

Post on 15-Jul-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Beginning

Christopher M. Judd

Development

iOS

Sunday, October 24, 2010

Page 2: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Christopher M. JuddPresident/Consultant of

leader

Creator of open source projects FallME and Fiddle

Columbus Developer User Group (CIDUG)

Sunday, October 24, 2010

Page 3: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Remarkable Ohio

Free

Developed for eTech Ohio and Ohio Historical CenterSunday, October 24, 2010

Page 4: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

University System Of Ohio

FreeDeveloped for eTech Ohio and University System Of Ohio

Sunday, October 24, 2010

Page 5: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Chmod

Free Judd Solutions

Sunday, October 24, 2010

Page 6: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

December 2008 issue

Sunday, October 24, 2010

Page 7: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Local Mobile Groups

CocoaHeads Ann ArborUsers group for iOS and Mac OS X DevelopersWebsite:  http://www.cocoaheads.org/us/AnnArborMichiganMailing List: http://groups.google.com/group/a2-cocoaheads

CocoaHeads Detroit (Birmingham)Users group for iOS and Mac OS X DevelopersWebsite: http://www.cocoaheads.org/us/DetroitMichiganMailing List: http://groups.google.com/group/cocoaheads-detroit

Mobile Monday Ann ArborGeneral interest mobile users groupWebsite: http://www.meetup.com/MoMoa2/

Mobile Monday DetroitGeneral interest mobile users groupWebsite: http://www.meetup.com/mobile-monday-detroit

Sunday, October 24, 2010

Page 8: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

iOS Devices

Sunday, October 24, 2010

Page 9: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Sunday, October 24, 2010

Page 10: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Sunday, October 24, 2010

Page 11: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Input

Multi-touch

Virtual Keyboard

Sunday, October 24, 2010

Page 12: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Location Aware

Sunday, October 24, 2010

Page 13: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Accelerometer/Gyroscope

Sunday, October 24, 2010

Page 14: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Camera/Video

Sunday, October 24, 2010

Page 15: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

iPhone Development

vs

Sunday, October 24, 2010

Page 16: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

iPhone SDK

Sunday, October 24, 2010

Page 17: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Advantages:Access native features

cameralocation awareness3D supportaccelerometer (fine grain)off-line access

PerformanceSQLite database

Disadvantages:Must know Objective-CNeed Mac and OSX LeopardGive up first born child in mountain of legal agreementsMust have application approved and vetted before distribution in App StoreProcess is on Apple’s timeline not yours

Sunday, October 24, 2010

Page 18: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

iPhone Developer Programs

DeveloperFreeCan not deploy to a device

Standard Program$99Deploy to up to 100 Ad Hoc devicesDeploy to App Store

Enterprise Program$299For developing internal application and deploying to company phones

Sunday, October 24, 2010

Page 19: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

What you need

MacMac OS X 10.6.x (Snow Leopard)iPhone, iPod Touch and/or iPad$99Join Standard Program

http://developer.apple.com/iosTo learn Objective-C

Sunday, October 24, 2010

Page 20: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Registration Process

Register for Standard ProgramRead lots of boring legal documents

WaitProve who you areWaitGain access to Program Portal for creating certificates

Sunday, October 24, 2010

Page 21: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

iPhone Web Development

Sunday, October 24, 2010

Page 22: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Advantages:Develop with Server-side technology of choice

Java Groovy/GrailsRuby.NETPHPPerl

Don’t have to deal with syncing data with cloudDeployment and schedule is under your controlEasier to deal with versioning

Disadvantages:Don’t have access to native featuresNot as glamorousNetwork performance

Sunday, October 24, 2010

Page 23: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Browser

Mobile Safari (WebKit)

HTML 4.01 & 5XHTML 1.0JavaScript 3

CSS 2.1 (partial 3.0)

XHTML Mobile Profile (MP)WAP 2.0

WAP/WML

DOM Level 2AJAX (XMLHTTPrequest)

Sunday, October 24, 2010

Page 24: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

iPhone SDK

Sunday, October 24, 2010

Page 25: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

FREE!!!

Sunday, October 24, 2010

Page 26: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

http://developer.apple.com/ios/Sunday, October 24, 2010

Page 27: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Xcode

InstrumentsInterface Builder

SimulatorIDE

GUI Builder Profiler

iPhone Simulator

Sunday, October 24, 2010

Page 28: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

MyWebBrowser Example

Sunday, October 24, 2010

Page 29: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

1. Create project2. Design interface3. Add component references4. Add event handler5. Connect components to references6. Connect events to event handler7. Implement even handler8. Run application9. Profile application

Sunday, October 24, 2010

Page 30: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

File > New Project > View-Based Application

Create Project

Sunday, October 24, 2010

Page 31: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Application Templates

Navigation-Based OpenGL ES Tab Bar Utility View-Based

Window-Based is total generic

Sunday, October 24, 2010

Page 32: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Sunday, October 24, 2010

Page 33: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Double clicking *.xib opens

Sunday, October 24, 2010

Page 34: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Text FieldPlaceholder: URL

Rounded Rect ButtonTitle: GO!

Web View

Design Interface

Sunday, October 24, 2010

Page 35: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

#import <UIKit/UIKit.h>

@interface mybrowserViewController : UIViewController {

IBOutlet UITextField *urlField; IBOutlet UIWebView *webView;}

-(IBAction) browseTo: (id) sender;

@end

Add Component and Even Handler

*ViewController.h

Sunday, October 24, 2010

Page 36: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Connect Component and Even Handler

Right Click or Control Click and DragSunday, October 24, 2010

Page 37: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Implement Event Handler*ViewController.m

#import "mybrowserViewController.h"

@implementation mybrowserViewController

-(IBAction) browseTo: (id) sender { // hide keyboard [urlField resignFirstResponder]; NSURL *url = [[NSURL alloc] initWithString:urlField.text]; NSURLRequest *request = [[NSURLRequest alloc] initWithURL: url]; [webView loadRequest:request]; [request release]; [url release];}

- (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning];}

- (void)dealloc { [super dealloc];}

@endSunday, October 24, 2010

Page 38: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Run Application

Sunday, October 24, 2010

Page 39: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Run Application on Device1. Create and Install Provisioning Profile 2. Set Executable Name

3. Select Code Signing Identity 4. Select DeviceSunday, October 24, 2010

Page 40: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

AnalyticsApple

Downloads

Analytic Companies

UsesNew UsersDevice TypesLocationsEvents

Sunday, October 24, 2010

Page 41: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Resources

The Objective-C Programming Language

Sunday, October 24, 2010

Page 42: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

Open Source Frameworks

Three20 Framework - http://github.com/facebook/three20

kissxml - http://code.google.com/p/kissxml/

json framework - http://code.google.com/p/json-framework/

Sunday, October 24, 2010

Page 43: Development · CocoaHeads Ann Arbor Users group for iOS and Mac OS X Developers ... distribution in App Store Process is on Apple’s timeline not yours Sunday, October 24, 2010

President/Consultant/Authoremail: [email protected]: www.juddsolutions.comblog: juddsolutions.blogspot.comtwitter: javajudd

Christopher M. Judd

Sunday, October 24, 2010