EcmascriptLogger2.0

back

Commands

Events

The ecmascript-logger is a noninteractive tool used to log all the source code executed by Opera's ECMAScript engine.

Requirements

req.log-source: Log script source

[Status: strawman requirement; author: lth]

All scripts compiled by the engine should be captured and displayed.

A logged script has three parts: type, url, and text.

(req.reformatting) Make Opera reformat the source code before logging

[Status: strawman requirement; author: lth]

The tool should allow the user to control whether Opera reformats the source code before sending it, provided the script logger is the only tool trying to control that behavior.

Configure

The tool can configure the logger by sending this command. If reformat is `true, source code will be reformatted before compilation (currently through an expensive process of compilation, decompilation, and recompilation of the decompiled data), and the reformatted code will be sent to the script logger tool.

command Configure(Config)
{
}
returns (Default)
{
}
= 1;

OnNewScript

event OnNewScript returns (ScriptInfo)
{
}
= 2;