private ActivityManager am; am = (ActivityManager) getSystemService(ACTIVITY_SERVICE); MemoryInfo outInfo = new ActivityManager.MemoryInfo(); am.getMemoryInfo(outInfo); return outInfo.availMem;
返回的是 long 型的byte数据。
2022-05-05 21:38:19
private ActivityManager am; am = (ActivityManager) getSystemService(ACTIVITY_SERVICE); MemoryInfo outInfo = new ActivityManager.MemoryInfo(); am.getMemoryInfo(outInfo); return outInfo.availMem;
返回的是 long 型的byte数据。
下一篇:oracle spatial初探