| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public long | getCurrentThreadAllocatedBytes()
Overrides sun. Overrides default com. Returns an approximation of the total amount of memory, in bytes, allocated in heap memory for the current thread. |
| public long | getThreadAllocatedBytes(long id)
Overrides sun. Implements com. Returns an approximation of the total amount of memory, in bytes, allocated in heap memory for the thread with the specified ID. The returned value is an approximation because some Java virtual machine implementations may use object allocation mechanisms that result in a delay between the time an object is allocated and the time its size is recorded. |
| public long[] | getThreadAllocatedBytes(long[] ids)
Overrides sun. Implements com. Returns an approximation of the total amount of memory, in bytes,
allocated in heap memory for each thread whose ID is in the input
array |
| public long[] | getThreadCpuTime(long[] ids)
Overrides sun. Implements com. Returns the total CPU time for each thread whose ID is
in the input array |
| public long[] | getThreadUserTime(long[] ids)
Overrides sun. Implements com. Returns the CPU time that each thread whose ID is in the input array
|
| public long | getTotalThreadAllocatedBytes()
Overrides sun. Overrides default com. Returns an approximation of the total amount of memory, in bytes, allocated in heap memory by all threads since the Java virtual machine started. |
| public boolean | isThreadAllocatedMemoryEnabled()
Overrides sun. Implements com. Tests if thread memory allocation measurement is enabled. |
| public boolean | isThreadAllocatedMemorySupported()
Overrides sun. Implements com. Tests if the Java virtual machine implementation supports thread memory allocation measurement. |
| public void | setThreadAllocatedMemoryEnabled(boolean enable)
Overrides sun. Implements com. Enables or disables thread memory allocation measurement. |
| HotSpotThreadImpl | back to summary |
|---|---|
| public HotSpotThreadImpl(VMManagement vm) | |
| getCurrentThreadAllocatedBytes | back to summary |
|---|---|
| public long getCurrentThreadAllocatedBytes() Overrides sun. Overrides default com. Doc from com. Returns an approximation of the total amount of memory, in bytes, allocated in heap memory for the current thread. The returned value is an approximation because some Java virtual machine implementations may use object allocation mechanisms that result in a delay between the time an object is allocated and the time its size is recorded. This is a convenience method for local management use and is equivalent to calling:
| |
| getThreadAllocatedBytes | back to summary |
|---|---|
| public long getThreadAllocatedBytes(long id) Overrides sun. Implements com. Doc from com. Returns an approximation of the total amount of memory, in bytes, allocated in heap memory for the thread with the specified ID. The returned value is an approximation because some Java virtual machine implementations may use object allocation mechanisms that result in a delay between the time an object is allocated and the time its size is recorded.
If the thread with the specified ID is a virtual thread, is not alive,
or does not exist, this method returns If thread memory allocation measurement is enabled after the thread has started, the Java virtual machine implementation may choose any time up to and including the time that the capability is enabled as the point where thread memory allocation measurement starts.
| |
| getThreadAllocatedBytes | back to summary |
|---|---|
| public long[] getThreadAllocatedBytes(long[] ids) Overrides sun. Implements com. Doc from com. Returns an approximation of the total amount of memory, in bytes,
allocated in heap memory for each thread whose ID is in the input
array
This method is equivalent to calling the
| |
| getThreadCpuTime | back to summary |
|---|---|
| public long[] getThreadCpuTime(long[] ids) Overrides sun. Implements com. Doc from com. Returns the total CPU time for each thread whose ID is
in the input array
This method is equivalent to calling the
| |
| getThreadUserTime | back to summary |
|---|---|
| public long[] getThreadUserTime(long[] ids) Overrides sun. Implements com. Doc from com. Returns the CPU time that each thread whose ID is in the input array
This method is equivalent to calling the
| |
| getTotalThreadAllocatedBytes | back to summary |
|---|---|
| public long getTotalThreadAllocatedBytes() Overrides sun. Overrides default com. Doc from com. Returns an approximation of the total amount of memory, in bytes, allocated in heap memory by all threads since the Java virtual machine started. The returned value is an approximation because some Java virtual machine implementations may use object allocation mechanisms that result in a delay between the time an object is allocated and the time its size is recorded.
| |
| isThreadAllocatedMemoryEnabled | back to summary |
|---|---|
| public boolean isThreadAllocatedMemoryEnabled() Overrides sun. Implements com. Doc from com. Tests if thread memory allocation measurement is enabled.
| |
| isThreadAllocatedMemorySupported | back to summary |
|---|---|
| public boolean isThreadAllocatedMemorySupported() Overrides sun. Implements com. Doc from com. Tests if the Java virtual machine implementation supports thread memory allocation measurement.
| |
| setThreadAllocatedMemoryEnabled | back to summary |
|---|---|
| public void setThreadAllocatedMemoryEnabled(boolean enable) Overrides sun. Implements com. Doc from com. Enables or disables thread memory allocation measurement. The default is platform dependent.
| |