Java Memory Used usedMemory()

Here you can find the source of usedMemory()

Description

used Memory

License

Open Source License

Declaration

public static long usedMemory() 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {

    public static long usedMemory() {
        return Runtime.getRuntime().totalMemory()
                - Runtime.getRuntime().freeMemory();
    }//from   w w w .  jav a  2 s .co m
}

Related

  1. memoryUsed()
  2. memoryUsed()
  3. memoryUsedInMB()
  4. stringMemoryUsedInMB()
  5. usedMemory()
  6. usedMemory()
  7. usedMemory()
  8. usedMemory()
  9. usedMemory()