提交 1652824c 编写于 作者: A andrewleo2013

refine code

上级 53f46d76
......@@ -167,8 +167,8 @@ public class CpuInfo {
traffic = -1;
else
traffic = (lastestTraffic - initialTraffic + 1023) / 1024;
processCpuRatio = fomart
.format(100 * ((double) (processCpu - processCpu2) / ((double) (totalCpu - totalCpu2))));
processCpuRatio = fomart.format(100 * ((double) (processCpu - processCpu2)
/ ((double) (totalCpu - totalCpu2))));
totalCpuRatio = fomart
.format(100 * ((double) ((totalCpu - idleCpu) - (totalCpu2 - idleCpu2)) / (double) (totalCpu - totalCpu2)));
long pidMemory = mi.getPidMemorySize(pid, context);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册