??????????У?????????鱻??app???????????????????????????ú?cpu?????????????????д??????????С?????????????????????
????IOS????????UNIX??????????????ssh?????????top????????????????????????????????????????ios?豸???????OpenSSH?????top??????????????xshell????????????????????????top?????????£?

?????????????????????£?
????1??????1???????е???????????緢??????????-???-??????-????????
????2?????????app????????????磺app1??app2
????2???????1??cpu????????????
????2???????????????
????3???????1????ios?豸????ssh????
????2?????app1???????????????棬????????????????top?????app1????????
????3??????top???????????cpu??????????????????洢??list1??
????4?????app2?????2????3??????裬????洢??list2??
????5????list1??list2?е?cpu???????????????????????????????????????????
???????? ????jar????
????1??ganymed-ssh2-build251?????ssh2Э????????????
????2??jfreechart-1.0.19?????????
?????????????????????????
????1???????????
????connection = new Connection(hostname?? port);
????connection.connect();
????boolean isAuthenticated = connection.authenticateWithPassword(username?? password);
????if (isAuthenticated == false)
????{
????throw new IOException("Authentication failed.");
????}
????2?????????????????
????Session sess = connection.openSession();
????sess.execCommand("top -l 2");
????InputStream stdout = new StreamGobbler(sess.getStdout());
????BufferedReader br = new BufferedReader(new InputStreamReader(stdout));
????????top -l 2?????????ν???????????????????????????μ?????????
????3????top????а????app?????????????????????????飬???ж?????????????app???????????????????????y??%CPU????????0.0%???????????top???????????????????н????%CPU?????0.0%?????????μ?????????????????????