Top
||
Section Contents
||
Permuted Index
SavaJe OS
1.1.0
Java applications running under
SavaJe OS
execute in a single
Java virtual machine (JVM). When an application is launched,
whether from the command line or from a GUI shell, a new
Java process (JProc
) is created.
Each JProc
receives its own storage block for the values of
statics. From the application programmer's point of view, creating
a new JProc
is just like starting up a new JVM. Static method calls
and static fields refer only to the current JProc
: there is no interference
with other calls or fields in different JProc
s.
At the same time, running multiple JProc
s in a single JVM saves
SavaJe OS
the overhead of creating multiple JVMs and multiple copies
of common classes.
Each JProc
also inherits a copy of
the current system properties, which becomes its local environment,
to use and to modify during its operation.
For example, the following program prints out the value of the
system property user.name
:
public class getProp { public static void main (String[] args) { System.out.println("user.name: " + System.getProperty("user.name")); } }
In this example, the application uses the system properties to find out
the current value of user.name
.
Once an application has a copy of the system properties, it can be
manipulated like any java.util.Properties
object.
policy(shell)
prop(shell)
run(shell)
run_java(doc)