I know how to us ps, psgrep, and top to get process information from the 
command line.

However, I'm looking for a specific piece of information about a given pid: 
whether the associated app is "swapped out". By this I mean the following: 
if the pid exists but the associated app is currently not running as the 
foreground app on the device for any reason, I consider it to be "swapped 
out", and I'd like to detect this state from within a shell script that is 
invoked on the command line.

I know that I can get this kind of information by using ActivityManager 
from within java. However, I'm wondering if there's a command-line way of 
getting this same info from inside of a shell script.

Thank you in advance for any suggestions.
.



-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to