|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.partnersoft.system.RuntimeLib
public class RuntimeLib
A library with handy routines for handling external execution etc.
| Constructor Summary | |
|---|---|
RuntimeLib()
|
|
| Method Summary | |
|---|---|
static void |
cleanupMemory()
Does it's damnedest to clear out memory, both used and available heap. |
static void |
execAndHalt(java.lang.String command)
Executes the given OS-specific command; then halts the current Java session. |
static void |
execAndHalt(java.lang.String command,
java.io.File currentDir)
Executes the given OS-specific command; then halts the current Java session. |
static void |
execAndWait(java.lang.String command)
Same as execAndWait(command, currentDir) but defaulted to the install dir. |
static void |
execAndWait(java.lang.String command,
java.io.File currentDir)
A wrapper for Runtime.exec() that handles the problems of grabbing the input streams and reading from them, and waits for completion. |
static java.lang.Process |
execNoWait(java.lang.String command)
Same as execNoWait(command, currentDir) but defaulted to the install directory. |
static java.lang.Process |
execNoWait(java.lang.String command,
java.io.File currentDir)
Same as execAndWait(command, currentDir) but does not wait - the process continues in a separate thread. |
static void |
launchAppAndHalt(java.lang.String appName)
Restart the Java session, calling the given application. |
static void |
launchAppAndHalt(java.lang.String appName,
java.io.File currentDir)
Restart the Java session, calling the given application. |
static void |
logMemoryUsage()
|
static void |
logOutput(java.lang.Process proc)
Logs all output from a process; waits for result. |
static void |
tossOutput(java.lang.Process proc)
Tosses all output from a process. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RuntimeLib()
| Method Detail |
|---|
public static void cleanupMemory()
public static void logMemoryUsage()
public static void execAndWait(java.lang.String command)
throws java.io.IOException
java.io.IOException
public static void execAndWait(java.lang.String command,
java.io.File currentDir)
throws java.io.IOException
java.io.IOException
public static java.lang.Process execNoWait(java.lang.String command)
throws java.io.IOException
java.io.IOException
public static java.lang.Process execNoWait(java.lang.String command,
java.io.File currentDir)
throws java.io.IOException
java.io.IOException
public static void execAndHalt(java.lang.String command)
throws java.io.IOException
java.io.IOException
public static void execAndHalt(java.lang.String command,
java.io.File currentDir)
throws java.io.IOException
java.io.IOException
public static void launchAppAndHalt(java.lang.String appName)
throws java.io.IOException
java.io.IOException
public static void launchAppAndHalt(java.lang.String appName,
java.io.File currentDir)
throws java.io.IOException
java.io.IOExceptionpublic static void tossOutput(java.lang.Process proc)
public static void logOutput(java.lang.Process proc)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||