
1、alps/frameworks/base/cmds/pm/src/com/android/commands/pm/Pm.java
public static void main(String[] args) { int exitCode = 1; try { exitCode = new Pm().run(args);/////step1 } catch (Exception e) { ********************************** }
public int run(String[] args) throws RemoteException { boolean validCommand = false; if (args.length < 1) { return showUsage(); } ****************************
if ("uninstall".equals(op)) { return runUninstall(); //////////step2 } ***************************** }
private int runUninstall() {

本文详细分析了在Android N系统中,通过adb shell pm uninstall命令卸载应用的流程。从Pm.java开始,探讨了Binder在进程间通信中的角色,接着讲解PackageManagerService如何处理卸载请求,最后阐述了ShellCommand和PackageManagerShellCommand的交互过程。
最低0.47元/天 解锁文章
1051

被折叠的 条评论
为什么被折叠?



