Guest User

Untitled

a guest
Feb 21st, 2018
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.68 KB | None | 0 0
  1. String[] command1 = null;
  2. command1 = new String[] {
  3. "adb", "shell", "monkey", "-p", " com.google.android.apps.maps", "-v", "500" };
  4. try {
  5. Process process = Runtime.getRuntime().exec(command1);
  6. BufferedReader bufferedReader = new BufferedReader(
  7. new InputStreamReader(process.getInputStream()));
  8. process.waitFor();
  9. String s;
  10. Log.d("BUFFEREDREADER_DUMP", "---------Begin---------");
  11. while ((s=bufferedReader.readLine())!=null)
  12. {
  13. System.out.println(s);
  14. }
  15. Log.d("BUFFEREDREADER_DUMP", "---------End---------");
  16. }catch (Exception e){
  17. e.printStackTrace();
  18. }
Add Comment
Please, Sign In to add comment