寻找银弹

致力于探寻软件开发中的本质问题

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

没有特别多时间来集中看objC和iOS的书,就上下班路上看了一下Standford的课程CS193P,入门绰绰有余了。

Course web site  ■ http://cs193p.stanford.edu/
• Other web sites
■ Apple Dev Center: http://developer.apple.com/
■ Developer Forums: http://devforums.apple.com/

External resources:
http://cs193p.com/
http://groups.google.com/group/iphone-appdev-auditors/


Cocoa Touch iPhone SDK 是基于 Coco API的Framework有 Foundation和UIKit


UIKit

User interface elements
Application runtime
Event handling
Hardware APIs


Foundation

Utility classes
Collection classes
Object wrappers for system services
Subset of Foundation in Cocoa


-InstanceMethod

+ClassMethod

UIAction

UIOutlet

Target - Action


Object creation
■ All objects allocated out of the heap
■ No stack based objects

id is Dynamically-typed object

Message Syntax:

[receiver message:arg1 andArg:arg2]

• Objects represented in format strings using %@

Selector 类似函数指针

Selectors include the name and all colons, for example:
! -(void)setName:(NSString *)name age:(int)age;
would have a selector:
! SEL sel = @selector(setName:age:);


Array - ordered collection of objects
• Dictionary - collection of key-value pairs
• Set - unordered collection of unique objects

 

 

 

posted on 2011-05-06 09:22  hchlee  阅读(416)  评论(0编辑  收藏  举报