Acknowledgements |
|
xi | |
Introduction |
|
xiii | |
|
1 Exploring the iPhone SDK and Basic Programming |
|
|
1 | (26) |
|
|
3 | (2) |
|
Documentation and Getting Help |
|
|
5 | (5) |
|
|
5 | (1) |
|
Apple's Online Documents and Forums |
|
|
6 | (1) |
|
|
6 | (1) |
|
|
6 | (1) |
|
|
7 | (3) |
|
Basic Programming Concepts Using C |
|
|
10 | (11) |
|
|
10 | (2) |
|
|
12 | (1) |
|
|
13 | (2) |
|
Objective-C's Main Method |
|
|
15 | (3) |
|
Header Files and Source Files |
|
|
18 | (3) |
|
|
21 | (1) |
|
|
21 | (6) |
|
Configuring Xcode's Display |
|
|
23 | (3) |
|
|
26 | (1) |
|
2 Primitive Data Types and Operators |
|
|
27 | (20) |
|
|
28 | (8) |
|
|
29 | (4) |
|
Numeric Types: Float and Double |
|
|
33 | (2) |
|
|
35 | (1) |
|
|
36 | (1) |
|
|
36 | (6) |
|
|
36 | (2) |
|
|
38 | (1) |
|
Equality and Logical Operators |
|
|
39 | (1) |
|
|
40 | (1) |
|
|
41 | (1) |
|
The UIWindow Application Template |
|
|
42 | (5) |
|
3 Flow Control Statements, Arrays, and Structures |
|
|
47 | (28) |
|
|
49 | (1) |
|
|
50 | (6) |
|
|
50 | (1) |
|
|
51 | (1) |
|
|
52 | (4) |
|
|
56 | (1) |
|
|
56 | (9) |
|
|
57 | (2) |
|
|
59 | (1) |
|
The If Else If Else Structure |
|
|
59 | (2) |
|
|
61 | (3) |
|
The Break and Continue Statements |
|
|
64 | (1) |
|
|
65 | (6) |
|
|
66 | (2) |
|
|
68 | (3) |
|
The UIView Controller's Life-Cycle Methods |
|
|
71 | (4) |
|
4 Classes, Objects, and Messaging |
|
|
75 | (36) |
|
Object-Oriented Programming vs. Procedural Programming |
|
|
77 | (1) |
|
|
77 | (2) |
|
Object-Oriented Programming: Classes and Objects |
|
|
79 | (4) |
|
|
81 | (1) |
|
|
82 | (1) |
|
|
83 | (1) |
|
|
83 | (1) |
|
|
84 | (1) |
|
Object-Oriented Programming: Behavior |
|
|
84 | (11) |
|
|
85 | (5) |
|
|
90 | (5) |
|
|
95 | (16) |
|
Class and Instance Methods |
|
|
96 | (3) |
|
Allocating and Initializing Objects |
|
|
99 | (1) |
|
|
100 | (1) |
|
Writing Custom Initializers |
|
|
100 | (3) |
|
Multiple Argument Methods |
|
|
103 | (8) |
|
5 Memory Management and Properties |
|
|
111 | (34) |
|
|
112 | (9) |
|
|
113 | (8) |
|
Encapsulation and Memory Management |
|
|
121 | (4) |
|
|
125 | (6) |
|
|
125 | (1) |
|
|
126 | (1) |
|
|
127 | (4) |
|
Ownership and Properties Revisited |
|
|
131 | (1) |
|
|
132 | (6) |
|
Autorelease and Custom Classes |
|
|
133 | (5) |
|
IBOutlet and Interface Builder |
|
|
138 | (5) |
|
Deallocating and Nil Revisited |
|
|
143 | (2) |
|
|
145 | (28) |
|
|
146 | (10) |
|
|
146 | (10) |
|
|
156 | (1) |
|
|
156 | (3) |
|
|
159 | (3) |
|
|
162 | (4) |
|
Replacing a Parent's Method |
|
|
162 | (1) |
|
Extending a Parent's Method |
|
|
163 | (3) |
|
No Overriding Instance Variables and No Overloading |
|
|
166 | (2) |
|
No Overriding Instance Variables |
|
|
167 | (1) |
|
|
167 | (1) |
|
Inheritance and UIView Controller |
|
|
168 | (5) |
|
7 Protocols and Categories |
|
|
173 | (40) |
|
|
174 | (33) |
|
|
175 | (1) |
|
|
175 | (1) |
|
|
176 | (10) |
|
|
186 | (2) |
|
|
188 | (4) |
|
|
192 | (1) |
|
Adopting Multiple Protocols |
|
|
193 | (4) |
|
|
197 | (4) |
|
Protocols and Delegates in UIKit |
|
|
201 | (6) |
|
|
207 | (6) |
|
|
208 | (5) |
|
8 Some Foundation Framework Classes |
|
|
213 | (24) |
|
NSString and NSMutableString |
|
|
215 | (5) |
|
|
220 | (2) |
|
NSDate and NSDateFormatter |
|
|
222 | (2) |
|
|
224 | (13) |
|
NSArray and NSMutable Array |
|
|
224 | (4) |
|
NSEnumerator and Fast Enumeration |
|
|
228 | (3) |
|
NSDictionary and NSMutable Dictionary |
|
|
231 | (6) |
|
|
237 | (28) |
|
|
238 | (3) |
|
|
239 | (1) |
|
NSSearch Path For Directories In Domains |
|
|
239 | (1) |
|
|
240 | (1) |
|
|
240 | (1) |
|
|
241 | (24) |
|
|
241 | (7) |
|
NSString, Paths, and Text Files |
|
|
248 | (6) |
|
|
254 | (11) |
|
10 Property Lists, NSCopy, and Archiving |
|
|
265 | (30) |
|
|
266 | (12) |
|
|
267 | (1) |
|
|
268 | (10) |
|
|
278 | (17) |
|
|
279 | (1) |
|
NSKeyed Archiver and NSKeyed Unarchiver |
|
|
279 | (16) |
|
|
295 | (20) |
|
|
296 | (5) |
|
Delaying a Selector or Running in Background |
|
|
300 | (1) |
|
|
301 | (10) |
|
|
307 | (4) |
|
|
311 | (4) |
|
12 The Model-View-Controller Design Pattern |
|
|
315 | (38) |
|
The Model-View-Controller Design Pattern |
|
|
316 | (8) |
|
|
324 | (29) |
|
|
328 | (25) |
Index |
|
353 | |