public class Memory
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private static java.lang.Runtime |
runtime |
Constructor and Description |
---|
Memory() |
Modifier and Type | Method and Description |
---|---|
static long |
available()
memory that is available including increasing total memory up to maximum
|
static long |
cores()
get number of CPU cores
|
static long |
deadlocks()
find out the number of thread deadlocks.
|
static long |
free()
memory that is free without increasing of total memory taken from os
|
static double |
load()
get the system load within the last minute
|
static void |
logDeadlocks()
write deadlocked threads as to the log as warning
|
static long |
maxMemory()
maximum memory the Java virtual will allocate machine; may vary over time in some cases
|
static long |
total()
currently allocated memory in the Java virtual machine; may vary over time
|
static long |
used()
memory that is currently bound in objects
|
public static final long free()
public static final long available()
public static final long maxMemory()
public static final long total()
public static final long used()
public static final long cores()
public static double load()
public static long deadlocks()
public static void logDeadlocks()