Class ExtendedRuntimeMXBeanImpl
java.lang.Object
com.ibm.lang.management.internal.ExtendedRuntimeMXBeanImpl
- All Implemented Interfaces:
RuntimeMXBean, PlatformManagedObject, RuntimeMXBean
Runtime type for
RuntimeMXBean
.- Since:
- 1.5
-
Nested Class Summary
Nested classes/interfaces declared in interface RuntimeMXBean
RuntimeMXBean.VMIdleStates
-
Method Summary
Modifier and TypeMethodDescriptionfinal String
If bootstrap class loading is supported by the virtual machine, returns a string containing the full bootstrap class path used by the boot class loader to locate and load class files.final String
Returns the class path string used by the system class loader to locate and load class files.double
Returns a double value which holds the system load average calculated for the minute preceding the call, where system load average is taken to mean the following:Returns a list of all of the input arguments passed to the virtual machine on start-up.static RuntimeMXBean
Singleton accessor method.final String
Returns the Java library path that will be used by the virtual machine to locate and load libraries.final String
Returns a string containing the management interface specification version that the virtual machine meets.final String
getName()
Returns the string name of this virtual machine.final ObjectName
Returns anObjectName
instance representing the object name of this platform managed object.final String
Returns the name of the Java virtual machine specification followed by this virtual machine.final String
Returns the name of the Java virtual machine specification vendor.final String
Returns the name of the Java virtual machine specification version.final long
Returns the time, in milliseconds, when the virtual machine was started.Returns a map of the names and values of every system property known to the virtual machine.final long
Returns the lifetime of the virtual machine in milliseconds.double
Returns a system load average calculated over the minute preceding the call averaged over the number of CPU available to Java virtual machine process.getVmId()
This is provided for the benefit of applications which use attach API to load JVMTI agents into their own JVMs.Returns current JVM Idle state.final String
Returns the name of the Java virtual machine implementation.final String
Returns the name of the Java virtual machine implementation vendor.final String
Returns the version of the Java virtual machine implementation.boolean
Query the state of the Attach API.boolean
Query the state of the Attach API.final boolean
Returns a boolean indication of whether or not the virtual machine supports a bootstrap class loading mechanism.boolean
isVMIdle()
Methods declared in class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods declared in interface PlatformManagedObject
getObjectName
Methods declared in interface RuntimeMXBean
getBootClassPath, getClassPath, getInputArguments, getLibraryPath, getManagementSpecVersion, getName, getPid, getSpecName, getSpecVendor, getSpecVersion, getStartTime, getSystemProperties, getUptime, getVmName, getVmVendor, getVmVersion, isBootClassPathSupported
-
Method Details
-
getInstance
Singleton accessor method.- Returns:
- the
RuntimeMXBeanImpl
singleton.
-
getCPULoad
public double getCPULoad()Returns a double value which holds the system load average calculated for the minute preceding the call, where system load average is taken to mean the following:The time-averaged value of the sum of the number of runnable entities running on the available processors and the number of runnable entities ready and queued to run on the available processors. The averaging technique adopted can vary depending on the underlying operating system.
- Specified by:
getCPULoad
in interfaceRuntimeMXBean
- Returns:
- normally, the system load average as a double. If the system load average is not obtainable (e.g. because the calculation may involve an unacceptable performance impact) then a negative value is returned.
- See Also:
-
getVMGeneratedCPULoad
public double getVMGeneratedCPULoad()Returns a system load average calculated over the minute preceding the call averaged over the number of CPU available to Java virtual machine process.- Specified by:
getVMGeneratedCPULoad
in interfaceRuntimeMXBean
- Returns:
- A double indicating the average system load per processor. If the system load average is not available, it returns a negative value to indicate this.
-
getVMIdleState
Returns current JVM Idle state.- Specified by:
getVMIdleState
in interfaceRuntimeMXBean
- Returns:
- JVM idle state value - i.e active / idle
-
isVMIdle
public boolean isVMIdle()- Specified by:
isVMIdle
in interfaceRuntimeMXBean
- Returns:
- true if JVM state is idle. Otherwise returns false
-
isAttachApiInitialized
public boolean isAttachApiInitialized()Description copied from interface:RuntimeMXBean
Query the state of the Attach API. Return false if the Attach API is: - still initializing - disabled - terminated by VM shutdown- Specified by:
isAttachApiInitialized
in interfaceRuntimeMXBean
- Returns:
- true if Attach API is initialized
-
isAttachApiTerminated
public boolean isAttachApiTerminated()Description copied from interface:RuntimeMXBean
Query the state of the Attach API. Return true if the Attach API is: - disabled - terminated by VM shutdown and false if it is - still initializing - initialized and running- Specified by:
isAttachApiTerminated
in interfaceRuntimeMXBean
- Returns:
- true if Attach API is terminated
-
getVmId
Description copied from interface:RuntimeMXBean
This is provided for the benefit of applications which use attach API to load JVMTI agents into their own JVMs.- Specified by:
getVmId
in interfaceRuntimeMXBean
- Returns:
- Attach API Virtual Machine ID of this VM
-
getBootClassPath
If bootstrap class loading is supported by the virtual machine, returns a string containing the full bootstrap class path used by the boot class loader to locate and load class files.An indication of whether or not the virtual machine supports a boot class loader mechanism can be found from invoking the
RuntimeMXBean.isBootClassPathSupported()
method.- Specified by:
getBootClassPath
in interfaceRuntimeMXBean
- Returns:
- the bootstrap classpath with each entry separated by the path separator character corresponding to the underlying operating system.
-
getClassPath
Returns the class path string used by the system class loader to locate and load class files. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.class.path" for the key.- Specified by:
getClassPath
in interfaceRuntimeMXBean
- Returns:
- the system classpath with each entry separated by the path separator character corresponding to the underlying operating system.
- See Also:
-
getLibraryPath
Returns the Java library path that will be used by the virtual machine to locate and load libraries. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.library.path" for the key.- Specified by:
getLibraryPath
in interfaceRuntimeMXBean
- Returns:
- the Java library path with each entry separated by the path separator character corresponding to the underlying operating system.
- See Also:
-
getManagementSpecVersion
Returns a string containing the management interface specification version that the virtual machine meets.- Specified by:
getManagementSpecVersion
in interfaceRuntimeMXBean
- Returns:
- the version of the management interface specification adhered to by the virtual machine.
-
getName
Returns the string name of this virtual machine. This value may be different for each particular running virtual machine.- Specified by:
getName
in interfaceRuntimeMXBean
- Returns:
- the name of this running virtual machine.
-
getSpecName
Returns the name of the Java virtual machine specification followed by this virtual machine. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.vm.specification.name" for the key.- Specified by:
getSpecName
in interfaceRuntimeMXBean
- Returns:
- the name of the Java virtual machine specification.
- See Also:
-
getSpecVendor
Returns the name of the Java virtual machine specification vendor. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.vm.specification.vendor" for the key.- Specified by:
getSpecVendor
in interfaceRuntimeMXBean
- Returns:
- the name of the Java virtual machine specification vendor.
- See Also:
-
getSpecVersion
Returns the name of the Java virtual machine specification version. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.vm.specification.version" for the key.- Specified by:
getSpecVersion
in interfaceRuntimeMXBean
- Returns:
- the Java virtual machine specification version.
- See Also:
-
getStartTime
public final long getStartTime()Returns the time, in milliseconds, when the virtual machine was started.- Specified by:
getStartTime
in interfaceRuntimeMXBean
- Returns:
- the virtual machine start time in milliseconds.
-
getUptime
public final long getUptime()Returns the lifetime of the virtual machine in milliseconds.- Specified by:
getUptime
in interfaceRuntimeMXBean
- Returns:
- the number of milliseconds the virtual machine has been running.
-
getVmName
Returns the name of the Java virtual machine implementation. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.vm.name" for the key.- Specified by:
getVmName
in interfaceRuntimeMXBean
- Returns:
- the name of the Java virtual machine implementation.
- See Also:
-
getVmVendor
Returns the name of the Java virtual machine implementation vendor. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.vm.vendor" for the key.- Specified by:
getVmVendor
in interfaceRuntimeMXBean
- Returns:
- the name of the Java virtual machine implementation vendor.
- See Also:
-
getVmVersion
Returns the version of the Java virtual machine implementation. The value is identical to that which would be obtained from a call toSystem.getProperty(java.lang.String)
supplying the value "java.vm.version" for the key.- Specified by:
getVmVersion
in interfaceRuntimeMXBean
- Returns:
- the version of the Java virtual machine implementation.
- See Also:
-
isBootClassPathSupported
public final boolean isBootClassPathSupported()Returns a boolean indication of whether or not the virtual machine supports a bootstrap class loading mechanism.- Specified by:
isBootClassPathSupported
in interfaceRuntimeMXBean
- Returns:
true
if supported,false
otherwise.
-
getInputArguments
Returns a list of all of the input arguments passed to the virtual machine on start-up. This will not include any input arguments that are passed into the application'smain(String[] args)
method.- Specified by:
getInputArguments
in interfaceRuntimeMXBean
- Returns:
- a list of strings, each one containing an argument to the virtual machine. If no virtual machine arguments were passed in at start-up time then this will be an empty list.
-
getSystemProperties
Returns a map of the names and values of every system property known to the virtual machine.- Specified by:
getSystemProperties
in interfaceRuntimeMXBean
- Returns:
- a map containing the names and values of every system property.
-
getObjectName
Returns anObjectName
instance representing the object name of this platform managed object.- Specified by:
getObjectName
in interfacePlatformManagedObject
- Returns:
- an
ObjectName
instance representing the object name of this platform managed object.
-