I know how to get the total loading time of a web page by using onPageStarted() and onPageFinished() in WebViewClient.
What I want to know is whether there is a way to extract detailed infor开发者_运维技巧mation on web page load such as time spent on parsing, rendering, etc.
Thank you in advance!
Use method profiling
in eclipse to get memory as well as time taken in each step of your application.
Have a look here. http://www.jpct.net/wiki/index.php/Profiling_Android_Applications
have a lok on its output format Time/Call
cell provides information regarding time ellapsed on particular action
Thanks Deepak
Have you tried WebView#debugDump()? It is marked as "deprecated", but it might still prove useful. Also try Profiling with Traceview, using the Debug.startMethodTracing()
and Debug.stopMethodTracing()
methods around your WebView start/finish locations. Then follow the instructions above to download the trace file and load it into traceview
, to see where time is spent.
精彩评论