Class: DuProcess

DuProcess

A class to launch and manage processes, using the system command line.

new DuProcess(processPath, args, timeout)

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6257
Constructs a new DuProcess instance
Name Type Default Description
processPath string The path to the process executable binary
args Array.<string> optional The common arguments used to run the process. You can append arguments each time you run the process with start(args)
timeout int 0 optional Waiting timeout after process start, in ms, 0 to avoid waiting, -1 for infinite. If the process times out, process will not be killed, the script will just stop waiting.

Members

staticDuProcess.argsArray.<any>

The common arguments used to run the process. You can append arguments each time you run the process with start(args)

static,readonlyDuProcess.isAppPackageBoolean

True if the process path leads to an application package (.app folder containing at least "/Contents/MacOS") on mac. False otherwise.

static,readonlyDuProcess.latestCommandstring

The latest command which has been run.

static,readonlyDuProcess.processPathstring

The path to the process executable binary

staticDuProcess.queueArray.<Array.<string>>

An Array of arguments array.
Arrays of arguments in the queue will be processed one after each other.
Update the Array and launch the queue with startQueue()

staticDuProcess.timeoutint

Waiting timeout after process start, in ms, 0 to avoid waiting, -1 for infinite.
If the process times out, process will not be killed, the script will just stop waiting. Default: 0

Methods

staticDuProcess.isAppPackage(path){bool}

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6514
Checks if a given path leads to an Application package on Mac, i.e. it's a path ending with .app containing at least Contents/MacOS/.
Name Type Description
path string | Folder | File The path to the file or folder to check.
Returns:
Type Description
bool true if path is an application package.

staticDuProcess.run(process, args){string}

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6500
Runs a command with some arguments.
Name Type Default Description
process string | File The process or a path to the process.
args Array.<string> [] optional The arguments to pass to the command.
Returns:
Type Description
string The output from the command.

buildCmd(args){string}

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6396
Builds and returns the command line
Name Type Description
args Array.<string> optional Args to append to DuProcess.args before starting
Returns:
Type Description
string The command

buildQueueCmd(){string}

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6448
Builds and returns the command line to launch the current queue
Returns:
Type Description
string The command

start(args, timeout)

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6332
Starts the process
Name Type Description
args Array Args to append to DuProcess.args before starting
timeout int optional Overrides the default timeout.

startCmd(cmd)

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6470
Starts a command (in another thread).
Name Type Description
cmd string The command to start

startQueue(timeout)

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6347
Starts the queue
Name Type Description
timeout int optional Overrides the default timeout.

waitForFinished(timeout)

D:/DEV_SRC/RxOT/DuAEF/DuESF/tools/build/output/DuESF.jsxinc, line 6364
Waits for the process to finish
Name Type Description
timeout int optional Overrides the default timeout.