|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--jmrun.JMRun
Provides:
Method Summary | |
static void |
execParam(java.lang.String cmdLine)
Runs command in "cmdLine" |
static boolean |
execWait(java.lang.String cmdLine,
java.lang.String syncPath,
boolean autoFileNameFlag,
long waitTime,
long sleepTime)
Runs application from "cmdLine" with file synchronization. execWait creates synchronization file, starts "cmdLine" command and waits till termination of this command, which is syncronized by means of existence of syncronization file. |
static boolean |
execWaitPref(java.lang.String cmdLine,
java.lang.String syncKey,
boolean autoKeyNameSuffixFlag,
long waitTime,
long sleepTime)
Runs application from "cmdLine" with Java Preferences synchronization. execWaitPref sets synchronization preference flag, starts "cmdLine" command and waits till termination of this command, which is syncronized by means of existence of syncronization preference flag. |
static boolean |
isSetPrefStr(java.lang.String key)
Checks if preferences key value is set to "1" returns true, else returns false |
static void |
main(java.lang.String[] args)
This is a dual-purpose method: 1. |
static void |
resetPrefFlag(java.lang.String key)
Removes preferences key |
static void |
setPrefFlag(java.lang.String key)
Sets preferences key value to "1" |
static boolean |
settleDllDestination(java.lang.String sourcePath,
java.lang.String destPath,
java.lang.String destPathSuffix,
java.lang.String dllFileName)
Checks for availability of the dllFileName in destPath folder. |
static void |
start(java.lang.String scriptFileName)
Runs commands from script file where each line is a separate command string |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static void execParam(java.lang.String cmdLine)
cmdLine
- command stringpublic static void start(java.lang.String scriptFileName)
scriptFileName
- file name with command lines;
if line starts with "//" or "rem" or ";",
or line is empty - these commands are ignoredpublic static boolean settleDllDestination(java.lang.String sourcePath, java.lang.String destPath, java.lang.String destPathSuffix, java.lang.String dllFileName)
sourcePath
- path to folder where .dll file is located, if it is null
this path will be assumed as "<user.dir>/../lib"destPath
- path to folder where .dll file should be copied to, if it is null
this path will be assumed as "<java.home>"destPathSuffix
- suffix to destPath path, may be nulldllFileName
- .dll filename without path
public static boolean execWait(java.lang.String cmdLine, java.lang.String syncPath, boolean autoFileNameFlag, long waitTime, long sleepTime)
cmdLine
- commandsyncPath
- path ( if autoFileNameFlag is true ) or filename ( if autoFileNameFlag is false ) of
synchronization file, if syncPath is null, syncPath = ".\sync.tmp"autoFileNameFlag
- waitTime
- synchronization wait time. If execution time of the called application is more
than waitTime, execWait deletes the synchronization file and continues its workflow.sleepTime
- cycle check time of synchronization file existence
public static boolean isSetPrefStr(java.lang.String key)
key
- preference key name
public static void setPrefFlag(java.lang.String key)
key
- preference key namepublic static void resetPrefFlag(java.lang.String key)
key
- preference key namepublic static boolean execWaitPref(java.lang.String cmdLine, java.lang.String syncKey, boolean autoKeyNameSuffixFlag, long waitTime, long sleepTime)
cmdLine
- commandsyncKey
- preferences key name, if syncKey is null, or "", syncKey = "syncKey"autoKeyNameSuffixFlag
- waitTime
- synchronization wait time. If execution time of the called application is more
than waitTime, execWait removes the synchronization preference flag and continues its workflow.sleepTime
- cycle check time of synchronization preference flag existence
public static void main(java.lang.String[] args)
1. Starts JMRun launcher from command line. Example1: javaw -cp <classpath> jmrun.JMRun [<scriptfile>]
2. Could be used to remove synchronization preference flag, i.e. be called from .cmd or .bat files. Example2: javaw -cp <classpath> jmrun.JMRun -rpf:<synchronization preference flag name>
args
- command line arguments
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |