简体   繁体   English

Android:确定应用程序使用情况

[英]Android: Determine Application Usage

I'm working on a project (or will be, if this is possible), and one of the key things I need to do is determine application usage. 我正在做一个项目(或者如果可能的话),而我需要做的关键事情之一就是确定应用程序的使用情况。 That is, what application are being used most often, and for the longest amount of time. 也就是说,最常使用的应用程序是最长的时间。

I have searched long and hard for a way to directly do this, and have come up with nothing. 我经过漫长而艰苦的搜索,找到了一种直接执行此操作的方法,却一无所获。 I know that things like Spare Parts achieve it by using private APIs, but obviously that doesn't help me. 我知道诸如Spare Parts之类的东西都是通过使用私有API来实现的,但是显然这对我没有帮助。 Can anyone recommend some effective way to gather the data I need, or another way in which to determine the things I need to figure out? 谁能推荐一些有效的方法来收集我需要的数据,或者另一种方法来确定我需要弄清楚的事情?

Can you run powertop on Android machines? 您可以在Android机器上运行powertop吗? It's an awesome tool, but it may require infrastructure not supported in default kernel builds. 这是一个很棒的工具,但是它可能需要默认内核构建中不支持的基础结构。

Less directly related to power , but still capable of giving you full-system information is oprofile . oprofile电源的关系不那么直接,但是仍然能够为您提供完整的系统信息。 It too might require infrastructure not supported in default kernel builds, but it can show full-system profiling information. 它也可能需要默认内核构建中不支持的基础结构,但是它可以显示完整的系统配置信息。

You will need to add instrumentation to your own application that keeps track of the time in each activity. 您将需要在自己的应用程序中添加工具,以跟踪每个活动中的时间。 There is no API for this in the platform. 平台中没有为此的API。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Android —我们如何确定每个应用程序的电池使用情况统计信息? - Android — How can we determine the Battery Usage statistics per application? 有没有办法确定weblogic中每个应用程序的内存使用情况? - Is there a way to determine the memory usage per application in weblogic? 确定应用程序是否已安装在android上 - Determine if application is installed on android Android应用程序上的高内存使用率 - High memory usage on Android Application 如何确定用户正在使用的应用程序(在android中)? - How to determine that an application in being used by the user (in android)? 如何确定导致 Java 应用程序内存使用率过高的原因? - How can I determine what's causing high memory usage in my Java application? 如何在Android应用程序中检查FD(文件描述符)表的当前使用情况 - How to check the current usage of FD(file descriptor) table in android application 如何检测Android应用程序的堆大小使用情况 - How do I detect the heap size usage of an android application 如何在 Android 中发现我的应用程序的内存使用情况? - How do I discover memory usage of my application in Android? 如何以编程方式禁用 android 中其他应用程序的网络使用? - how to disable network usage for other application in android programmatically?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM