Preface |
|
xi | |
|
Part I Tasks and Operations |
|
|
|
A Note About the State of Mobile Development |
|
|
1 | (2) |
|
|
3 | (24) |
|
|
3 | (1) |
|
|
4 | (10) |
|
How to Create Your App's Starting UI Controller |
|
|
4 | (2) |
|
How to Change the Active UI Controller |
|
|
6 | (5) |
|
Understanding the UI Controller Life Cycle |
|
|
11 | (3) |
|
|
14 | (11) |
|
How to Create Your App's Starting UI Controller |
|
|
14 | (3) |
|
How to Change the Active UI Controller |
|
|
17 | (4) |
|
Understanding the Controller Life Cycle |
|
|
21 | (4) |
|
|
25 | (2) |
|
|
27 | (18) |
|
|
27 | (1) |
|
|
28 | (6) |
|
|
28 | (5) |
|
|
33 | (1) |
|
|
34 | (1) |
|
|
34 | (9) |
|
|
35 | (2) |
|
|
37 | (3) |
|
Interface Builder to the Rescue |
|
|
40 | (1) |
|
|
41 | (1) |
|
|
42 | (1) |
|
|
43 | (2) |
|
|
45 | (14) |
|
|
45 | (1) |
|
|
45 | (8) |
|
How to Create a Custom View |
|
|
46 | (5) |
|
|
51 | (2) |
|
|
53 | (4) |
|
How to Create a Custom View |
|
|
53 | (2) |
|
|
55 | (2) |
|
|
57 | (2) |
|
|
59 | (18) |
|
|
59 | (1) |
|
|
60 | (10) |
|
Receive and React to a Tap |
|
|
60 | (5) |
|
Receive and React to Keyboard Input |
|
|
65 | (3) |
|
|
68 | (2) |
|
|
70 | (6) |
|
Receive and React to a Tap |
|
|
70 | (2) |
|
Receive and React to Keyboard Input |
|
|
72 | (2) |
|
|
74 | (2) |
|
|
76 | (1) |
|
|
77 | (22) |
|
|
77 | (1) |
|
|
77 | (8) |
|
Use a Callback to React to an Operation |
|
|
78 | (4) |
|
Dispatch a Message to Any Interested Subscribers |
|
|
82 | (2) |
|
Listen for, and React to, Messages Dispatched Within a System |
|
|
84 | (1) |
|
|
85 | (12) |
|
Use a Callback to React to an Operation |
|
|
85 | (6) |
|
Dispatch a Message to Any Interested Subscribers |
|
|
91 | (2) |
|
Listen for, and React to, Messages Dispatched Within a System |
|
|
93 | (1) |
|
Closures Instead of Selectors |
|
|
94 | (1) |
|
Stop Listening for Notifications |
|
|
95 | (2) |
|
|
97 | (2) |
|
|
99 | (16) |
|
|
99 | (1) |
|
|
99 | (8) |
|
Get Properties from the File Like Size or Last Modified Date |
|
|
100 | (1) |
|
Read and Write Data to and from a File |
|
|
101 | (4) |
|
Copy Data from One File to Another |
|
|
105 | (2) |
|
|
107 | (6) |
|
Get Properties from the File Like Size or Last Modified Date |
|
|
107 | (3) |
|
Reading and Writing Data to and from a File |
|
|
110 | (1) |
|
Copy Data from One File to Another |
|
|
111 | (2) |
|
|
113 | (2) |
|
|
115 | (14) |
|
|
115 | (1) |
|
|
115 | (7) |
|
Establish a Database Connection |
|
|
116 | (1) |
|
Create a Database Table or Persistent Object |
|
|
117 | (1) |
|
Write Data to That Table or Persistent Object |
|
|
118 | (1) |
|
Read Data from That Table or Persistent Object |
|
|
119 | (3) |
|
|
122 | (6) |
|
Set Up and Connect to a Persistence Layer |
|
|
122 | (2) |
|
Define and Create a Database Table or Persistent Object |
|
|
124 | (1) |
|
Write and Persist Data to SQLite |
|
|
125 | (2) |
|
|
127 | (1) |
|
|
128 | (1) |
|
8 Concurrency (Multi-Threading) |
|
|
129 | (34) |
|
|
129 | (1) |
|
|
129 | (10) |
|
Perform a Task in a Background Thread |
|
|
130 | (3) |
|
Act on the Results of Work Performed in the Background Thread on the Main Thread |
|
|
133 | (1) |
|
|
134 | (5) |
|
|
139 | (3) |
|
Perform a Task in a Background Thread |
|
|
139 | (2) |
|
Act on the Results of Work Performed in the Background Thread on the Main Thread |
|
|
141 | (1) |
|
|
142 | (3) |
|
|
145 | (1) |
|
|
145 | (1) |
|
|
146 | (4) |
|
Read and Print a Text File on a Remote Server |
|
|
146 | (1) |
|
Make an HTTP POST Request |
|
|
147 | (2) |
|
|
149 | (1) |
|
|
150 | (11) |
|
Read and Print a Text File on a Remote Server |
|
|
151 | (2) |
|
Make an HTTP POST Request |
|
|
153 | (3) |
|
|
156 | (5) |
|
|
161 | (2) |
|
|
163 | (10) |
|
|
163 | (1) |
|
|
163 | (5) |
|
Use Framework-Provided Tools to Show the User Feedback |
|
|
163 | (1) |
|
|
164 | (2) |
|
|
166 | (2) |
|
|
168 | (4) |
|
Use Framework-Provided Tools to Show the User Feedback |
|
|
168 | (2) |
|
|
170 | (2) |
|
|
172 | (1) |
|
|
173 | (10) |
|
|
173 | (1) |
|
|
173 | (3) |
|
|
174 | (1) |
|
|
175 | (1) |
|
Work with User Preferences in a Multiple User Application |
|
|
175 | (1) |
|
|
176 | (6) |
|
|
176 | (3) |
|
|
179 | (1) |
|
Work with User Preferences in a Multiple User Application |
|
|
180 | (2) |
|
|
182 | (1) |
|
12 Serialization and Transports |
|
|
183 | (16) |
|
|
183 | (1) |
|
|
183 | (7) |
|
Serialize and Deserialize an Object Instance |
|
|
183 | (7) |
|
|
190 | (7) |
|
Serialize and Deserialize an Object Instance |
|
|
191 | (5) |
|
|
196 | (1) |
|
|
197 | (2) |
|
|
199 | (6) |
|
|
199 | (1) |
|
|
199 | (2) |
|
Add Functionality to Existing APIs |
|
|
199 | (2) |
|
|
201 | (3) |
|
Add Functionality to Existing APIs |
|
|
201 | (3) |
|
|
204 | (1) |
|
|
205 | (16) |
|
|
205 | (1) |
|
|
205 | (9) |
|
Set Up and Run Unit Tests |
|
|
209 | (3) |
|
Set Up and Run Integration Tests |
|
|
212 | (2) |
|
|
214 | (3) |
|
Set Up and Run Unit Tests |
|
|
214 | (3) |
|
|
217 | (4) |
|
|
|
15 Welcome and Environment Setup |
|
|
221 | (10) |
|
Comparing Native Development to Cross-Platform Tools |
|
|
221 | (2) |
|
|
222 | (1) |
|
|
222 | (1) |
|
|
223 | (6) |
|
|
223 | (6) |
|
|
229 | (1) |
|
|
229 | (2) |
|
|
231 | (22) |
|
|
232 | (10) |
|
|
232 | (6) |
|
|
238 | (4) |
|
|
242 | (1) |
|
Building Our First Screen |
|
|
243 | (8) |
|
|
243 | (3) |
|
|
246 | (5) |
|
|
251 | (2) |
|
17 Listing Data in the App |
|
|
253 | (36) |
|
|
253 | (16) |
|
|
254 | (10) |
|
|
264 | (5) |
|
|
269 | (2) |
|
|
270 | (1) |
|
Lists, Lists, and More Lists! |
|
|
271 | (3) |
|
|
271 | (1) |
|
|
272 | (2) |
|
|
274 | (3) |
|
|
277 | (10) |
|
|
277 | (7) |
|
|
284 | (3) |
|
|
287 | (2) |
|
|
289 | (18) |
|
Dynamic Data in List Views |
|
|
289 | (7) |
|
|
290 | (3) |
|
|
293 | (3) |
|
It's Time for Our Model Objects to Get Real |
|
|
296 | (1) |
|
JSON for One, JSON for All |
|
|
297 | (2) |
|
Switch the Model Layer to JSON |
|
|
299 | (7) |
|
|
299 | (6) |
|
|
305 | (1) |
|
|
306 | (1) |
|
|
307 | (34) |
|
|
307 | (9) |
|
|
308 | (4) |
|
|
312 | (4) |
|
|
316 | (3) |
|
|
317 | (1) |
|
|
318 | (1) |
|
|
319 | (18) |
|
|
320 | (9) |
|
|
329 | (8) |
|
|
337 | (2) |
|
|
338 | (1) |
|
|
339 | (2) |
|
20 Networking and Our App |
|
|
341 | (24) |
|
|
342 | (7) |
|
|
344 | (2) |
|
|
346 | (3) |
|
Building a Search Endpoint |
|
|
349 | (2) |
|
Installing Node and Express |
|
|
349 | (2) |
|
|
351 | (1) |
|
|
351 | (13) |
|
|
352 | (3) |
|
|
355 | (9) |
|
|
364 | (1) |
Index |
|
365 | |