This is an ideal book for Android programmers who want to explore SQLite databases based on Android applications. The general competency level expected of the reader is prior knowledge of developing applications and basic knowledge of Android and SQL.
Preface |
|
1 | (4) |
|
|
5 | (20) |
|
|
6 | (2) |
|
|
8 | (1) |
|
|
8 | (1) |
|
|
8 | (1) |
|
|
9 | (1) |
|
|
9 | (1) |
|
A quick review of database fundamentals |
|
|
9 | (1) |
|
What is an SQLite statement? |
|
|
10 | (2) |
|
|
12 | (1) |
|
|
12 | (1) |
|
|
12 | (1) |
|
|
13 | (1) |
|
The Date and Time datatype |
|
|
13 | (1) |
|
|
14 | (1) |
|
|
15 | (1) |
|
|
16 | (1) |
|
|
16 | (1) |
|
The SQLiteOpenHelper class |
|
|
16 | (3) |
|
|
19 | (3) |
|
|
22 | (1) |
|
|
22 | (1) |
|
|
23 | (2) |
|
Chapter 2 Connecting the Dots |
|
|
25 | (24) |
|
|
26 | (4) |
|
A database handler and queries |
|
|
30 | (2) |
|
Building the Create query |
|
|
32 | (3) |
|
Building the Insert query |
|
|
35 | (5) |
|
Building the Delete query |
|
|
40 | (1) |
|
Building the Update query |
|
|
41 | (2) |
|
Connecting the Ul and database |
|
|
43 | (5) |
|
|
48 | (1) |
|
Chapter 3 Sharing is Caring |
|
|
49 | (24) |
|
What is a content provider? |
|
|
50 | (1) |
|
Using existing content providers |
|
|
51 | (1) |
|
What is a content resolver? |
|
|
51 | (3) |
|
Creating a content provider |
|
|
54 | (1) |
|
Understanding content URIs |
|
|
55 | (1) |
|
Declaring our contract class |
|
|
56 | (2) |
|
Creating UriMatcher definitions |
|
|
58 | (1) |
|
Implementing the core methods |
|
|
59 | (1) |
|
Initializing the provider through the onCreate() method |
|
|
59 | (1) |
|
Querying records through the query() method |
|
|
59 | (2) |
|
Adding records through the insert() method |
|
|
61 | (1) |
|
Updating records through the update() method |
|
|
61 | (1) |
|
Deleting records through the delete() method |
|
|
62 | (1) |
|
Getting the return type of data through the getType() method |
|
|
63 | (1) |
|
Adding a provider to a manifest |
|
|
64 | (1) |
|
|
64 | (8) |
|
|
72 | (1) |
|
Chapter 4 Thread Carefully |
|
|
73 | (22) |
|
Loading data with CursorLoader |
|
|
73 | (1) |
|
|
74 | (1) |
|
|
75 | (1) |
|
|
75 | (5) |
|
|
80 | (1) |
|
ContentProvider and permissions |
|
|
80 | (2) |
|
|
82 | (3) |
|
General tips and libraries |
|
|
85 | (1) |
|
|
86 | (1) |
|
Database minus SQL statements |
|
|
87 | (3) |
|
Shipping with a prepopulated database |
|
|
90 | (3) |
|
|
93 | (2) |
Index |
|
95 | |
Sunny Kumar Aditya has been working on the Android platform for the past 4 years. His tryst with Android began with his college project, and he continued with his work in R&D at HCL Infosystems Ltd. Sunny loves to stay up to date with the latest trends and practices in Android development. Apart from building Android applications, he writes at www.deadmango.com. He is currently the head of Android development at Yamunix. Vikash Kumar Karn is an IIIT Allahabad alumnus and an ECE student whose love for code drove him towards the software development field. He has worked with leading multinationals and is currently working at Samsung Research Institute, Bangalore, exploring Android. Vikash likes to learn the intricacies of the Android framework and help newcomers in this field. Some of his applications, such as Movtan Fishing and Compare Pictures, can be found on the Play Store.