📌  相关文章
📜  android以编程方式检查可用空间 - 无论代码示例

📅  最后修改于: 2022-03-11 14:57:23.230000             🧑  作者: Mango

代码示例2
//gets available ram space during runtime
ActivityManager actManager = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
MemoryInfo memInfo = new ActivityManager.MemoryInfo();
actManager.getMemoryInfo(memInfo);
long totalMemory = memInfo.totalMem;