I have an Android app for which I wanted in COSU mode. I have successfully activated my device into Device Administrator mode. Now I want the data of the usage of other apps used daily. For eg: Facebook, etc. I need the data to monitor usage of other apps. How can I achieve this programmatically? TIA.
Asked
Active
Viewed 75 times
0
-
by logs are you refering to logCat ?! https://stackoverflow.com/questions/12692103/read-logcat-programmatically-within-application – Amir Hossein Mirzaei Jun 12 '18 at 07:31
-
@AmirHosseinMirzaei - No, I want the data. I saw the confusion, hence I have edited the question. I want the data of other apps that are being used in that device. – Name is Nilay Jun 12 '18 at 07:54
2 Answers
1
Not 100% sure what you are looking for, but do you mean something like UsageStatsManager
(documentation)?

BBB
- 302
- 2
- 10
0
Using Android library class TrafficStats, you can find how much bytes received/sent across mobile networks since the last boot.
Also, you can find how much of bytes transmitted/received by the given UID since device boot. and you can find any package UID with RunningAppProcessInfo
.
Here is a detailed answer on this here and an article on Creating a network monitor

isamirkhaan1
- 749
- 7
- 19