
android framework
weihaolu
这个作者很懒,什么都没留下…
展开
-
Android中wtf的含义
看Android framework源码时,老是看到诸如"wtf" "reportwtf" 的句子,其实Android中的"wtf"代表了报告一个永远不可能发生的情况,原意:"what a terrible failure" ,可理解为"what the fuck"级别的错误。该错误将被记录在assert(中断)级别的log打印中。附 某句源码:Slog.wtf(TAG, "BOO...原创 2019-05-24 17:07:59 · 4705 阅读 · 3 评论 -
android framework中contexwrapper和contextimpl的关联过程(基于Android 5.1)
我们都知道,contexwrapper是contextimpl的代理类,那么它是在哪里把contextimpl和contextwrapper绑定在一起的呢,如下为调用过程:LoadedApk.java:ContextImpl appContext = ContextImpl.createAppContext(mActivityThread, this);app = mActivityT...原创 2019-05-28 14:31:57 · 544 阅读 · 0 评论 -
Android clearCallingIdentity和restoreCallingIdentity作用
IPCThreadState对象维护了2个变量pid_tmCallingPid;uid_tmCallingUid;从变量名称来看,这2个变量保存了进程的PID和UID,并且由于这两个变量由IPCThreadState对象维护,可见它们是与IPC相关的。具体它们保存的是IP...转载 2019-06-03 13:51:03 · 485 阅读 · 0 评论