Reputation: 73
I want to know the average start-up time of all the apps on android device. And this is supposed to be done by my app. So, is it possible to get such information from the app level programatically?
Upvotes: 0
Views: 986
Reputation: 1116
The way I am trying to solve this problem is by using a service to monitor the logs that will start a timer when app X is started. We have that working properly. The problem we are having is how to define the app as done loading. Once we have that we can gather data. But I am still looking for a way to know when app X moves from the onCreate() method from one activity to the onCreate() method of another. This will obviously only work for apps that have a loading activity for their app.
Effectively, this a really hard problem to both define and solve. If you ever come up with anything different than what I have, I'd love to hear it.
Upvotes: 0
Reputation: 1535
I assume you mean the time it takes for a given app to complete its onCreate()
method. You might be able to do something on a rooted phone with extending onCreate()
with a timer that logs to somewhere for your app.
Upvotes: 1
Reputation: 3236
This isn't going to work. You would have to start an app and time it, but you do not have access to the information about when another app has finished loading. Furthermore,.. how do you define start-up time? The time taken until the app opens or the time until past the loading screen.. or the time until past the splash screen...?
Upvotes: 0