问题描述
我想开发一个Android应用程序,当安装在设备中的Android应用程序打开并关闭时,会发现该应用程序。
我在开发者网站上找不到任何实质内容。
我尝试了什么:
一个活动有生命周期方法,通过它我们可以知道什么时候创建一个活动以及何时销毁它但我想知道是否有任何支持来知道应用程序何时启动和停止。
我的意思是一个应用程序可能有多个活动,因此活动生命周期方法不会派上用场来确定解决方案。
I want to develop an Android Application which finds, when an Android Application installed in the device, is opened and when the same is closed.
I couldn't find anything substantial in Developers website.
What I have tried:
An activity has lifecycle methods through which we know when an activity is created and when it is destroyed but I want to know is there any support to know when an application is started and stopped.
I mean an application could have more than one activity so activity lifecycle methods won't come in handy to determine the solution.
这篇关于每次启动和销毁Android应用程序(非活动)时,活动管理器是否在android中提供回调?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!