Process

Process

Information about current executable. Do not create it directly - use a global variable process.

Constructor

new Process()

Mixes In:
To Do:
  • Add a emitted events description

Members

startupPath: String readonly

Path to directory from which server executed (CWD)

binPath: String readonly

The main executable full path (excluding .exe file name)

configPath: String readonly

Path to config file process started with

env: Object:.<string:, string:> readonly

Operation system environment variables

argv: Array:.<string:> readonly

Process argv list. You can use helper class modules\cmd\argv.js to work with this array.

isServer: Number readonly

In case this is server-side thread === 1 else (client theread) === 0

isWebSocketServer: Number readonly

In case this is WebSocket server-side thread === 1 else not defined

isWebSocketEnabled: Number readonly

When WebSockets are enabled === 1 else not defined

isDebug: Number readonly

true if server executed with -dev command line switch.

startupMode: String readonly

The UB process startup mode. One of "Service", "Console", "GUI", "CmdLine"

Methods

cwd()String

Return current working directory for process (actually Process#startupPath

nextTick(cb)

Just a hack for nodeJS compatribility (async emulation)
Arguments:
  1. cb (function)

listenerCount(emitter, type)Number

Return the number of listeners for a given event.
Arguments:
  1. emitter (EventEmitter)
  2. type (String)
Mixes In: