This documentation differs from the official API.
Jadeite adds
extra features to the API including:
variable font sizes,
constructions examples,
placeholders for classes and methods, and auto-generated “See Also” links.
Additionally it
is missing some items found in standard Javadoc documentation, including:
generics type information,
“Deprecated” tags and comments,
“See Also” links,
along with other minor differences.
Please send any questions or feedback to
bam@cs.cmu.edu.
java.lang.management
interface RuntimeMXBean
-
Most common way to construct:
-
RuntimeMXBean mxbean = ManagementFactory.getRuntimeMXBean();
Based on 105 examples
public interface RuntimeMXBean
The management interface for the runtime system of
the Java virtual machine.
A Java virtual machine has a single instance of the implementation
class of this interface. This instance implementing this interface is
an MXBean
that can be obtained by calling
the {@link ManagementFactory#getRuntimeMXBean} method or
from the {@link ManagementFactory#getPlatformMBeanServer
platform MBeanServer} method.
The ObjectName for uniquely identifying the MXBean for
the runtime system within an MBeanServer is:
{@link ManagementFactory#RUNTIME_MXBEAN_NAME
java.lang:type=Runtime}
This interface defines several convenient methods for accessing
system properties about the Java virtual machine.
Method Summary |
String |
Returns the boot class path that is used by the bootstrap class loader
to search for class files.
|
String |
Returns the Java class path that is used by the system class loader
to search for class files.
|
List |
Returns the input arguments passed to the Java virtual machine
which does not include the arguments to the main method.
|
String |
Returns the Java library path.
|
String |
Returns the version of the specification for the management interface
implemented by the running Java virtual machine.
|
String |
Returns the name representing the running Java virtual machine.
|
String |
Returns the Java virtual machine specification name.
|
String |
Returns the Java virtual machine specification vendor.
|
String |
Returns the Java virtual machine specification version.
|
long |
Returns the start time of the Java virtual machine in milliseconds.
|
Map |
Returns a map of names and values of all system properties.
|
long |
Returns the uptime of the Java virtual machine in milliseconds.
|
String |
Returns the Java virtual machine implementation name.
|
String |
Returns the Java virtual machine implementation vendor.
|
String |
Returns the Java virtual machine implementation version.
|
boolean |
Tests if the Java virtual machine supports the boot class path
mechanism used by the bootstrap class loader to search for class
files.
|
getBootClassPath
public String getBootClassPath()
-
Returns the boot class path that is used by the bootstrap class loader
to search for class files.
Multiple paths in the boot class path are separated by the
path separator character of the platform on which the Java
virtual machine is running.
A Java virtual machine implementation may not support
the boot class path mechanism for the bootstrap class loader
to search for class files.
The {@link #isBootClassPathSupported} method can be used
to determine if the Java virtual machine supports this method.
- Returns:
- the boot class path.
getClassPath
public String getClassPath()
-
Returns the Java class path that is used by the system class loader
to search for class files.
This method is equivalent to {@link System#getProperty
System.getProperty("java.class.path")}.
Multiple paths in the Java class path are separated by the
path separator character of the platform of the Java virtual machine
being monitored.
- Returns:
- the Java class path.
getInputArguments
public List getInputArguments()
-
Returns the input arguments passed to the Java virtual machine
which does not include the arguments to the main method.
This method returns an empty list if there is no input argument
to the Java virtual machine.
Some Java virtual machine implementations may take input arguments
from multiple different sources: for examples, arguments passed from
the application that launches the Java virtual machine such as
the 'java' command, environment variables, configuration files, etc.
Typically, not all command-line options to the 'java' command
are passed to the Java virtual machine.
Thus, the returned input arguments may not
include all command-line options.
MBeanServer access:
The mapped type of List is String[].
- Returns:
- a list of String objects; each element
is an argument passed to the Java virtual machine.
getLibraryPath
public String getLibraryPath()
-
Returns the Java library path.
This method is equivalent to {@link System#getProperty
System.getProperty("java.library.path")}.
Multiple paths in the Java library path are separated by the
path separator character of the platform of the Java virtual machine
being monitored.
- Returns:
- the Java library path.
getManagementSpecVersion
public String getManagementSpecVersion()
-
Returns the version of the specification for the management interface
implemented by the running Java virtual machine.
- Returns:
- the version of the specification for the management interface
implemented by the running Java virtual machine.
getName
public String getName()
-
Returns the name representing the running Java virtual machine.
The returned name string can be any arbitrary string and
a Java virtual machine implementation can choose
to embed platform-specific useful information in the
returned name string. Each running virtual machine could have
a different name.
- Returns:
- the name representing the running Java virtual machine.
getSpecName
public String getSpecName()
-
Returns the Java virtual machine specification name.
This method is equivalent to {@link System#getProperty
System.getProperty("java.vm.specification.name")}.
- Returns:
- the Java virtual machine specification name.
getSpecVendor
public String getSpecVendor()
-
Returns the Java virtual machine specification vendor.
This method is equivalent to {@link System#getProperty
System.getProperty("java.vm.specification.vendor")}.
- Returns:
- the Java virtual machine specification vendor.
getSpecVersion
public String getSpecVersion()
-
Returns the Java virtual machine specification version.
This method is equivalent to {@link System#getProperty
System.getProperty("java.vm.specification.version")}.
- Returns:
- the Java virtual machine specification version.
getStartTime
public long getStartTime()
-
Returns the start time of the Java virtual machine in milliseconds.
This method returns the approximate time when the Java virtual
machine started.
- Returns:
- start time of the Java virtual machine in milliseconds.
getSystemProperties
public Map getSystemProperties()
-
Returns a map of names and values of all system properties.
This method calls {@link System#getProperties} to get all
system properties. Properties whose name or value is not
a String are omitted.
MBeanServer access:
The mapped type of Map is
{@link javax.management.openmbean.TabularData TabularData}
with two items in each row as follows:
Item Name |
Item Type |
key |
String |
value |
String |
- Returns:
- a map of names and values of all system properties.
getUptime
public long getUptime()
-
Returns the uptime of the Java virtual machine in milliseconds.
- Returns:
- uptime of the Java virtual machine in milliseconds.
getVmName
public String getVmName()
-
Returns the Java virtual machine implementation name.
This method is equivalent to {@link System#getProperty
System.getProperty("java.vm.name")}.
- Returns:
- the Java virtual machine implementation name.
getVmVendor
public String getVmVendor()
-
Returns the Java virtual machine implementation vendor.
This method is equivalent to {@link System#getProperty
System.getProperty("java.vm.vendor")}.
- Returns:
- the Java virtual machine implementation vendor.
getVmVersion
public String getVmVersion()
-
Returns the Java virtual machine implementation version.
This method is equivalent to {@link System#getProperty
System.getProperty("java.vm.version")}.
- Returns:
- the Java virtual machine implementation version.
isBootClassPathSupported
public boolean isBootClassPathSupported()
-
Tests if the Java virtual machine supports the boot class path
mechanism used by the bootstrap class loader to search for class
files.
- Returns:
- true if the Java virtual machine supports the
class path mechanism; false otherwise.
This documentation differs from the official API.
Jadeite adds
extra features to the API including:
variable font sizes,
constructions examples,
placeholders for classes and methods, and auto-generated “See Also” links.
Additionally it
is missing some items found in standard Javadoc documentation, including:
generics type information,
“Deprecated” tags and comments,
“See Also” links,
along with other minor differences.
Please send any questions or feedback to
bam@cs.cmu.edu.
This page displays the
Jadeite version of the documention, which is derived from the offical documentation that contains this copyright notice:
The official Sun™ documentation can be found here at
http://java.sun.com/javase/6/docs/api/.