Launch Time of an app

前端 未结 5 910
暗喜
暗喜 2021-01-03 13:05

What is the best way to launch an app and calculate its launch time in android(if it can be done with some code,then its better)

5条回答
  •  有刺的猬
    2021-01-03 13:54

    There will be an automatic log something like

    system_process I/ActivityManager﹕ Displayed com.android.vending/com.google.android.finsky.activities.MainActivity: +549ms
    

    to show the launch time of an app from the user typing on it to the app be ready to interact with user further more. That is from ActivityManager.

    Also, using log to measure the time from onCreate() to onResume should be another good way.

提交回复
热议问题