In-depth understanding of Android: Volume II
Basic Information
Author: Deng fanping
Press: Machinery Industry Press
ISBN: 9787111389187
Mounting time:
Published on: February 1, August 2012
Start: 16
Page number: 1
Version: 1-1
Category: Computer> Software and programming> mobile development> android
For more information, see "deep understanding of Android: Volume II".
Introduction
Books
Computer books
Deep understanding of Android: Volume II is the second book in the "deep understanding of Android" series. After its first book was published, it was highly praised by many readers and passed on to the android developer community. This book not only inherits the advantages of the first book, but also corrects some shortcomings in its micropoints. It also makes innovations in the overall thinking of writing, it emphasizes the analysis of the internal implementation principles and working mechanisms of each module in the Android system from the perspective of system designers. In terms of specific content, this book focuses on the Java layer of the android framework and provides in-depth and meticulous analysis of the core modules and services involved in the Java layer. Through this book, readers can not only have a deeper understanding of the Android system, but also master the ability to analyze large complex source code.
The book consists of eight chapters: Chapter 1st describes the preparations required to read this book, including downloading and compiling the android 4.0 source code, setting up the eclipse environment, and running the Android system process (system_process) in Chapter 2nd, the implementation of Java binder and messagequeue is deeply analyzed. Chapter 3rd details the working principle of systemserver, these services include entropyservice, dropboxmanagerservice, diskstatsservice, devicestoragemonitorservice, samplingprofilerservice, and clipboardservice; chapter 2 analyzes in detail the packagemanagerservice, which is responsible for querying package information and installing, uninstalling, and updating apk in the system. Chapter 2 analyzes the core service powermanagerservic, which is responsible for Power Management in the Android system. The principles of E are deeply analyzed. Chapter 6th focuses on activitymanagerservice, in-depth research on its startup, activity creation and startup, broadcastreceiver working principle, and process management in Android; chapter 2 conducts in-depth analysis on the creation and startup of contentprovider, the implementation of SQLite, cursor query, and close; Chapter 7th takes contentservice and accountmanagerservice as the analysis object, this section describes the implementation of the data update notification mechanism, account management, data synchronization, and other related knowledge.
Directory
In-depth understanding of Android: Volume II
Preface
Chapter 1 build the android source code work environment/1
1.1 Android system architecture/2
1.2 build a Development Environment/3
1.2.1 download source code/3
1.2.2 compile source code/4
1.2.3 use eclipse to debug system_process/5
1.3 summary of this chapter/11
Chapter 2 deep understanding of Java binder and messagequeue/12
2.1 Overview/13
2.2 binder Architecture Analysis in the Java Layer/13
2.2.1 binder Architecture Overview/13
2.2.2 initialize the Java-layer binder framework/14
2.2.3 addservice instance analysis/17
2.2.4 Java layer binder architecture Summary/26
2.3 two-sector messagequeue/27
2.3.1 create messagequeue/27
2.3.2 extract message/28
2.3.3 nativepollonce function analysis/31
2.3.4 messagequeue Summary/41
2.4 Summary of this chapter/42
Chapter 4 in-depth understanding of systemserver/44
3.1 Overview/45
3.2 systemserver analysis/45
3.2.1 main function analysis/45
3.2.2 Service Group/48
3.3 entropyservice analysis/49
3.4 dropboxmanagerservice analysis/50
3.4.1 DBMS constructor analysis/51
3.4.2 Add a dropbox log file/51
3.4.3 DBMS and settings database/56
3.5 diskstatsservice and devicestoragemonitorservice analysis/56
3.5.1 diskstatsservice analysis/56
3.5.2 devicestoragemanagerservice analysis/58
3.6 samplingprofilerservice analysis/60
3.6.1 samplingprofilerservice constructor analysis/61
3.6.2 samplingprofilerintegration analysis/62
3.7 clipboardservice analysis/64
3.7.1 copy data to clipboard/64
3.7.2 paste data from clipboard/67
3.7.3 permission management in CBS/69
3.8 summary of this chapter/73
Chapter 4 deep understanding of packagemanagerservice/74
4.1 Overview/75
4.2 first recognized packagemanagerservice/76
4.3 Main Function Analysis of PKMs/77
4.3.1 preparations for Constructor analysis/78
4.3.2 constructor analysis: scanning package/90
4.3.3 scanning of constructor analysis/105
4.3.4 PKMs constructor Summary/105
4.4 APK installation analysis/105
4.4.1 ADB install analytics/105
4.4.2 PM analysis/107
4.4.3 installpackagewithverification function analysis/109
4.4.4 APK Installation Process summary/121
4.4.5 verification/122
4.5 queryintentactivities analysis/124
4.5.1 introduction to intent and intentfilter/124
4.5.2 activity information management/125
4.5.3 search and analysis of intent matching/128
4.5.4 queryintentactivities Summary/131
4.6 introduction to installd and usermanager/131
4.6.1 installd introduction/131
4.6.2 usermanager introduction/136
4.7 guide to this chapter/138
4.8 Summary of this chapter/138
Chapter 2 in-depth understanding of powermanagerservice/5th
5.1 Overview/140
5.2 First recognized powermanagerservice/140
5.2.1 PMS constructor analysis/141
5.2.2 init analytics/141
5.2.3 systemready analysis/147
5.2.4 bootcomplete processing/148
5.2.5 Summary of powermanagerservice at the beginning/149
5.3 PMS wakelock analysis/149
5.3.1 wakelock client analysis/149
5.3.2 PMS acquirewakelock analysis/151
5.3.3 introduction to power and lightservice/160
5.3.4 Summary of wakelock/163
5.4 useractivity and power key processing analysis/164
5.4.1 useractivity analysis/164
5.4.2 power key processing analysis/167
5.5 batteryservice and batterystatsservice analysis/168
5.5.1 batteryservice analysis/169
5.5.2 batterystatsservice analysis/172
5.5.3 batteryservice and batterystatsservice Summary/182
5.6 guide to this chapter/183
5.7 summary of this chapter/183
Chapter 2 deep understanding of activitymanagerservice/6th
6.1 Overview/185
6.2 First recognized activitymanagerservice/186
6.2.1 Main Function Analysis of activitymanagerservice/187
6.2.2 AMS setsystemprocess analysis/197
6.2.3 AMS installsystemproviders function analysis/202
6.2.4 AMS systemready analysis/211
6.2.5 Summary of activitymanagerservice/218
6.3 startactivity analysis/219
6.3.1 start from AM/219
6.3.2 startactivityandwait Function Analysis of AMS/221
6.3.3 startactivitylocked analysis/230
6.4 broadcast and broadcastreceiver analysis/265
6.4.1 registerreceiver Process Analysis/267
6.4.2 sendbroadcast Process Analysis/272
6.4.3 broadcast_intent_msg message processing function/276
6.4.4 broadcast Analysis of Application Process processing/282
6.4.5 broadcast processing summary/284
6.5 startservice by image/285
6.5.1 service knowledge/285
6.5.2 startservice flowchart/286
6.6 process management in AMS/287
6.6.1 introduction to Linux Process Management/287
6.6.2 introduction to process management in Android/289
6.6.3 AMS Process Management Function Analysis/294
6.6.4 AMS Process Management Summary/305
6.7 crash processing of APP/305
6.7.1 Application Process crash processing/306
6.7.2 AMS handleapplicationcrash analysis/306
6.7.3 appdeathrecipient binderdied analysis/309
6.7.4 Summary of crash processing in the app/313
6.8 guide to this chapter/314
6.9 summary of this chapter/315
Chapter 2 in-depth understanding of contentprovider/7th
7.1 Overview/317
7.2 mediaprovider startup and creation/318
7.2.1 getcontentresolver Function Analysis of Context/318
7.2.2 mediastore. image. Media query function analysis/319
7.2.3 Summary of mediaprovider startup and creation/329
7.3 SQLite database creation analysis/330
7.3.1 SQLite and sqlitedatabase families/330
7.3.2 mediaprovider create database analysis/335
7.3.3 sqlitedatabase database creation analysis summary/344
7.4 Implementation of the query function of cursor/345
7.4.1 extract query key points/346
7.4.2 mediaprovider query analysis/349
7.4.3 query Key Point Analysis/356
7.4.4 Summary of cursor query Implementation/368
7.5 Implementation Analysis of the cursor close function/368
7.5.1 client close analysis/369
7.5.2 server close analysis/371
7.5.3 finalize function analysis/372
7.5.4 Summary of the cursor close function/373
7.6 contentresolver openassetfiledescriptor function analysis/373
7.6.1 openassetfiledescriptor client call analysis/374
7.6.2 contentprovider's opentypedassetfile function analysis/376
7.6.3 cross-process file descriptor transfer/379
7.6.4 openassetfiledescriptor function analysis summary/384
7.7 guide to this chapter/384
7.8 Summary of this chapter/385
Chapter 2 in-depth understanding of contentservice and accountmanagerservice/8th
8.1 Overview/387
8.2 data update notification mechanism analysis/387
8.2.1 first recognized contentservice/388
8.2.2 contentresovler's registercontentobserver analysis/389
8.2.3 contentresolver policychange analysis/391
8.2.4 summary and in-depth discussion on the data update notification mechanism/393
8.3 accountmanagerservice analysis/395
8.3.1 first recognized accountmanagerservice/396
8.3.2 accountmanager addaccount analysis/402
8.3.3 analysis summary of accountmanagerservice/414
8.4 Data Synchronization management syncmanager analysis/415
8.4.1 initial knowledge of syncmanager/415
8.4.2 contentresolver requestsync analysis/424
8.4.3 syncmanager analysis summary/436
8.5 guide to this chapter/437
8.6 summary of this chapter/437
Planning roadmap for "in-depth understanding of Android" series/438
This book is from: China Interactive publishing network