The dispatch function is used to execute a command. Commands can be dispatched with their arguments included in the command string, with their arguments provided as a JavaScript object, or in both formats.
Dispatching commands, from various files...// Dispatching a command with no arguments... dispatch ("version"); // Dispatching a command with a single argument, embedded into the // command string... dispatch ("restore-layout default"); // Dispatching a command with the argument provided in a JavaScript object... dispatch ("find-script", { scriptWrapper: e.breakpoint.scriptWrapper, targetPc: e.breakpoint.pc }); // Dispatching with parameters in two places. The object will be used // as the base for the parameter object. String parameters will override // anything on the object. dispatch ("pref maxStringLength", { isInteractive: e.isInteractive });
The isInteractive parameter is implicitly taken by every command. If true, the command should be invoked as if the user typed in the Interactive Session view. This is usually used to decide whether or not to display an acknowledgement message to the Interactive Session, via the feedback function.
Help text for commands dispatched above...