iOS Development using Xcode4

juggleroffbeatΚινητά – Ασύρματες Τεχνολογίες

19 Ιουλ 2012 (πριν από 5 χρόνια και 1 μήνα)

325 εμφανίσεις

iOS Development
using Xcode4
Mark Brindle
13 July 2011
Thursday, 14 July 2011
Our Project

Timecard app used for Battle Of The Mobiles

Today’s aim is to start simple

Further sessions will expand and refine our project
Thursday, 14 July 2011
Design principles

XCode’s Frameworks rely on design patterns

Model View Controller:

Strategy

Composite

Observer

Delegate
Thursday, 14 July 2011
MVC
Controller
View
Model
UITableViewController
UITableView
Core Data
Composite
Implements
Observer
Controller implements Strategy
for the View
Thursday, 14 July 2011
Objective-C

Classes

Inheritance

Protocols (interface definitions)
@interface
UITableViewController :
UIViewController

<
UITableViewDelegate
,
UITableViewDataSource
> {

@private

UITableViewStyle
_tableViewStyle;

id
_keyboardSupport;

id
_staticDataSource;

struct
{

int
clearsSelectionOnViewWillAppear:
1
;
} _tableViewControllerFlags;
}
Thursday, 14 July 2011
Model

BaseMO

Common base class

Project

top level grouping to record time against

ProjectItem

An individual task of interest

Timecard

Instance of time recorded
Thursday, 14 July 2011
Initial view

Simple table view to contain
our projects

Navigation controls allow us
to add / delete projects
Thursday, 14 July 2011
Demo
Thursday, 14 July 2011
TableView Cells

Four styles available:

Default

Subtitle

Value1

Value2

textLabel & detailTextLabel

Image can also be included
Screenshot from a sample application in Erica Sadun’s book
“The iPhone Developer’s Cookbook”
Thursday, 14 July 2011
Thank you

Questions?
Thursday, 14 July 2011