List of utility methods to do Memory Max
int | maxMemoryInMbs() max Memory In Mbs return (int) (Runtime.getRuntime().maxMemory() / (1024 * 1024)); |
double | maxMemoryMB() Get maximum memory in megabytes return megaBytes(Runtime.getRuntime().maxMemory());
|
long | memoryMax() memory Max long mem = 0; for (int i = 0; i < 10; i++) mem += runtime.maxMemory(); mem /= 10; return mem; |
int | memoryMax() memory Max Runtime runtime = Runtime.getRuntime();
return Math.round(runtime.maxMemory() / 1024f);
|