scala.sys
package scala.sys
Type members
Classlikes
A bidirectional map wrapping the java System properties.
Changes to System properties will be immediately visible in the map,
and modifications made to the map will be immediately applied to the
System properties. If a security manager is in place which prevents
the properties from being read or written, the AccessControlException
will be caught and discarded.
Value members
Methods
Register a shutdown hook to be run when the VM exits.
The hook is automatically registered: the returned value can be ignored,
but is available in case the Thread requires further modification.
It can also be unregistered by calling ShutdownHookThread#remove().
Note that shutdown hooks are NOT guaranteed to be run.
- Value Params
- body
-
the body of code to run at shutdown
- Returns
-
the Thread which will run the shutdown hook.
- See also
- Source
- (source)
Returns all active thread in the current thread's thread group and subgroups.
- Returns
-
an IndexedSeq containing the threads.
- Source
- (source)
An immutable Map representing the current system environment.
If lookup fails, use
System.getenv(_)
for case-insensitive lookup
on a certain platform. If that also fails, throw NoSuchElementException
.
- Returns
-
a Map containing the system environment variables.
- Source
- (source)
A bidirectional, mutable Map representing the current system Properties.
- Returns
-
a SystemProperties.
- See also
- Source
- (source)