| java.lang.Object | |
| ↳ | java.lang.Runtime |
This class, with the exception of the exec() APIs, must be implemented by the VM vendor. The exec() APIs must first do any required security checks, and then call org.apache.harmony.luni.internal.process.SystemProcess.create(). The Runtime interface.
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Registers a new virtual-machine shutdown hook.
| |||||||||||
Return the number of processors, always at least one.
| |||||||||||
Execute progArray[0] in a separate platform process.
| |||||||||||
Execute prog in a separate platform process The new process uses the
environment provided in envp
| |||||||||||
Execute program in a separate platform process The new process inherits
the environment of the caller.
| |||||||||||
Execute prog in a separate platform process The new process uses the
environment provided in envp
| |||||||||||
Execute progArray[0] in a separate platform process The new process
inherits the environment of the caller.
| |||||||||||
Execute progArray[0] in a separate platform process The new process uses
the environment provided in envp
| |||||||||||
Causes the virtual machine to stop running, and the program to exit.
| |||||||||||
Returns the amount of free memory resources which are available to the
running program.
| |||||||||||
Indicates to the virtual machine that it would be a good time to collect
available memory.
| |||||||||||
This method is deprecated.
Use InputStreamReader
| |||||||||||
This method is deprecated.
Use OutputStreamWriter
| |||||||||||
Return the single Runtime instance
| |||||||||||
Causes the virtual machine to stop running, and the program to exit.
| |||||||||||
Loads and links the library specified by the argument.
| |||||||||||
Loads and links the library specified by the argument.
| |||||||||||
Return the maximum memory that will be used by the virtual machine, or
Long.MAX_VALUE.
| |||||||||||
De-registers a previously-registered virtual-machine shutdown hook.
| |||||||||||
Provides a hint to the virtual machine that it would be useful to attempt
to perform any outstanding object finalizations.
| |||||||||||
This method is deprecated.
This method is unsafe.
| |||||||||||
Returns the total amount of memory resources which is available to (or in
use by) the running program.
| |||||||||||
Turns the output of debug information for instructions on or off.
| |||||||||||
Turns the output of debug information for methods on or off.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class java.lang.Object
| |||||||||||
Registers a new virtual-machine shutdown hook.
| hook | the hook (a Thread) to register |
|---|
Return the number of processors, always at least one.
Execute progArray[0] in a separate platform process. The new process uses the environment provided in envp
| progArray | the array containing the program to execute a well as any arguments to the program. |
|---|---|
| envp | the array containing the environment to start the new process in. |
| directory | the directory in which to execute progArray[0]. If null, execute in same directory as parent process. |
| IOException | if the program cannot be executed |
|---|---|
| SecurityException | if the current SecurityManager disallows program execution |
Execute prog in a separate platform process The new process uses the environment provided in envp
| prog | the name of the program to execute |
|---|---|
| envp | the array containing the environment to start the new process in. |
| IOException | if the program cannot be executed |
|---|---|
| SecurityException | if the current SecurityManager disallows program execution |
Execute program in a separate platform process The new process inherits the environment of the caller.
| prog | the name of the program to execute |
|---|
| IOException | if the program cannot be executed |
|---|---|
| SecurityException | if the current SecurityManager disallows program execution |
Execute prog in a separate platform process The new process uses the environment provided in envp
| prog | the name of the program to execute |
|---|---|
| envp | the array containing the environment to start the new process in. |
| directory | the initial directory for the subprocess, or null to use the directory of the current process |
| IOException | if the program cannot be executed |
|---|---|
| SecurityException | if the current SecurityManager disallows program execution |
Execute progArray[0] in a separate platform process The new process inherits the environment of the caller.
| progArray | the array containing the program to execute as well as any arguments to the program. |
|---|
| IOException | if the program cannot be executed |
|---|---|
| SecurityException | if the current SecurityManager disallows program execution |
Execute progArray[0] in a separate platform process The new process uses the environment provided in envp
| progArray | the array containing the program to execute a well as any arguments to the program. |
|---|---|
| envp | the array containing the environment to start the new process in. |
| IOException | if the program cannot be executed |
|---|---|
| SecurityException | if the current SecurityManager disallows program execution |
Causes the virtual machine to stop running, and the program to exit. If runFinalizersOnExit(true) has been invoked, then all finalizers will be run first.
| code | the return code. |
|---|
| SecurityException | if the running thread is not allowed to cause the vm to exit. |
|---|
Returns the amount of free memory resources which are available to the running program.
Indicates to the virtual machine that it would be a good time to collect available memory. Note that, this is a hint only.
Return the single Runtime instance
Causes the virtual machine to stop running, and the program to exit. Finalizers will not be run first. Shutdown hooks will not be run.
| code | the return code. |
|---|
| SecurityException | if the running thread is not allowed to cause the vm to exit. |
|---|
Loads and links the library specified by the argument.
| pathName | the absolute (ie: platform dependent) path to the library to load |
|---|
| UnsatisfiedLinkError | if the library could not be loaded |
|---|---|
| SecurityException | if the library was not allowed to be loaded |
Loads and links the library specified by the argument.
| libName | the name of the library to load |
|---|
| UnsatisfiedLinkError | if the library could not be loaded |
|---|---|
| SecurityException | if the library was not allowed to be loaded |
Return the maximum memory that will be used by the virtual machine, or Long.MAX_VALUE.
De-registers a previously-registered virtual-machine shutdown hook.
| hook | the hook (a Thread) to de-register |
|---|
Provides a hint to the virtual machine that it would be useful to attempt to perform any outstanding object finalizations.
This method is deprecated.This method is unsafe.
Ensure that, when the virtual machine is about to exit, all objects are finalized. Note that all finalization which occurs when the system is exiting is performed after all running threads have been terminated.
| run | true means finalize all on exit. |
|---|
Returns the total amount of memory resources which is available to (or in use by) the running program.
Turns the output of debug information for instructions on or off.
| enable | if true, turn trace on. false turns trace off. |
|---|
Turns the output of debug information for methods on or off.
| enable | if true, turn trace on. false turns trace off. |
|---|