Android-Activity5.3情景3之完整Log參考

本文出自 “阿敏其人” 簡(jiǎn)書博客,轉(zhuǎn)載或引用請(qǐng)注明出處。

這是Android-Activity所應(yīng)該了解的大概就這樣。(中)情景3里面的log記錄。

如果有興趣看,下面這部分摘取的情況3完整的log記錄步驟。

==== 打開app1

Recent tasks:
* Recent #0: TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
* Recent #1: TaskRecord{5295e6f8 #1 A=com.android.launcher U=0 sz=1}
* Recent #2: TaskRecord{52ac09c4 #89 A=com.android.systemui U=0 sz=0}

Running activities (most recent first):
  TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
    Run #0: ActivityRecord{52947afc u0 com.amqr.taskaffinity1/.MainActivity1 t90}

      
=====  打開app1的other頁(yè)面

Recent tasks:
 * Recent #0: TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=1}
 * Recent #1: TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
 * Recent #2: TaskRecord{5295e6f8 #1 A=com.android.launcher U=0 sz=1}
 * Recent #3: TaskRecord{52ac09c4 #89 A=com.android.systemui U=0 sz=0}

Running activities (most recent first):
  TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=1}
    Run #1: ActivityRecord{529208ac u0 com.amqr.taskaffinity1/.App1Other t91}
  TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
    Run #0: ActivityRecord{52947afc u0 com.amqr.taskaffinity1/.MainActivity1 t90}

 ==== 按下home

 Recent tasks:
 * Recent #0: TaskRecord{5295e6f8 #1 A=com.android.launcher U=0 sz=1}
 * Recent #1: TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=1}
 * Recent #2: TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
 * Recent #3: TaskRecord{52ac09c4 #89 A=com.android.systemui U=0 sz=0}

Running activities (most recent first):
  TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=1}
    Run #1: ActivityRecord{529208ac u0 com.amqr.taskaffinity1/.App1Other t91}
  TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
    Run #0: ActivityRecord{52947afc u0 com.amqr.taskaffinity1/.MainActivity1 t90}

=====  打開 app2

Recent tasks:
* Recent #0: TaskRecord{52ac226c #92 A=com.amqr.taskaffinity2 U=0 sz=1}
* Recent #1: TaskRecord{5295e6f8 #1 A=com.android.launcher U=0 sz=1}
* Recent #2: TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=1}
* Recent #3: TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
* Recent #4: TaskRecord{52ac09c4 #89 A=com.android.systemui U=0 sz=0}

Running activities (most recent first):
  TaskRecord{52ac226c #92 A=com.amqr.taskaffinity2 U=0 sz=1}
    Run #2: ActivityRecord{52aba490 u0 com.amqr.taskaffinity2/.MainActivity2 t92}
  TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=1}
    Run #1: ActivityRecord{529208ac u0 com.amqr.taskaffinity1/.App1Other t91}
  TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
    Run #0: ActivityRecord{52947afc u0 com.amqr.taskaffinity1/.MainActivity1 t90}

======  打開app2的other頁(yè)面

Recent tasks:
* Recent #0: TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=2}
* Recent #1: TaskRecord{52ac226c #92 A=com.amqr.taskaffinity2 U=0 sz=1}
* Recent #2: TaskRecord{5295e6f8 #1 A=com.android.launcher U=0 sz=1}
* Recent #3: TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
* Recent #4: TaskRecord{52ac09c4 #89 A=com.android.systemui U=0 sz=0}

Running activities (most recent first):
  TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=2}
    Run #3: ActivityRecord{52a305fc u0 com.amqr.taskaffinity2/.App2Other t91}
  TaskRecord{52ac226c #92 A=com.amqr.taskaffinity2 U=0 sz=1}
    Run #2: ActivityRecord{52aba490 u0 com.amqr.taskaffinity2/.MainActivity2 t92}
  TaskRecord{52a8eab0 #91 A=com.amqr.independent U=0 sz=2}
    Run #1: ActivityRecord{529208ac u0 com.amqr.taskaffinity1/.App1Other t91}
  TaskRecord{52997fe8 #90 A=com.amqr.taskaffinity1 U=0 sz=1}
    Run #0: ActivityRecord{52947afc u0 com.amqr.taskaffinity1/.MainActivity1 t90}

======  我們加多一個(gè)頁(yè)面,一樣singleTask+tsakAffinity,由app2的other頁(yè)面接著打開

Recent tasks:
* Recent #0: TaskRecord{52a8d110 #100 A=com.amqr.independent U=0 sz=3}
* Recent #1: TaskRecord{52a9d0f4 #101 A=com.amqr.taskaffinity2 U=0 sz=1}
* Recent #2: TaskRecord{5295e6f8 #1 A=com.android.launcher U=0 sz=1}
* Recent #3: TaskRecord{529c16d8 #99 A=com.amqr.taskaffinity1 U=0 sz=1}
* Recent #4: TaskRecord{52ab46ac #98 A=com.android.systemui U=0 sz=0}

Running activities (most recent first):
  TaskRecord{52a8d110 #100 A=com.amqr.independent U=0 sz=3}
    Run #4: ActivityRecord{52a92c0c u0 com.amqr.taskaffinity2/.App2_3Activity t100}
    Run #3: ActivityRecord{52a4f4d8 u0 com.amqr.taskaffinity2/.App2Other t100}
  TaskRecord{52a9d0f4 #101 A=com.amqr.taskaffinity2 U=0 sz=1}
    Run #2: ActivityRecord{5299485c u0 com.amqr.taskaffinity2/.MainActivity2 t101}
  TaskRecord{52a8d110 #100 A=com.amqr.independent U=0 sz=3}
    Run #1: ActivityRecord{52987b44 u0 com.amqr.taskaffinity1/.App1Other t100}
  TaskRecord{529c16d8 #99 A=com.amqr.taskaffinity1 U=0 sz=1}
    Run #0: ActivityRecord{529835bc u0 com.amqr.taskaffinity1/.MainActivity1 t99}

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容