Java Memory Max getJvmMaxMemory()

Here you can find the source of getJvmMaxMemory()

Description

get Jvm Max Memory

License

Apache License

Declaration

public static long getJvmMaxMemory() 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    private static final long K2M = 1024l * 1024l;

    public static long getJvmMaxMemory() {
        return Runtime.getRuntime().maxMemory() / K2M;
    }/*from w  w  w  .java  2s  .  co  m*/
}

Related

  1. checkMaxMemory()
  2. freeMaxMemory()
  3. getJavaMaxMemory()
  4. getMaximumMemory()
  5. getMaximumMemory()
  6. getMaximumMemory()
  7. getMaximumMemory()