function RequireFunc() { if (arguments.length === 1) { if ((arguments[0] instanceof Object) && !Array.isArray(arguments[0])) { RequireFunc.config(arguments[0]); return; } if (typeof arguments[0] === 'string') { return moduleManager.synchronousRequire(arguments[0]); } } if (arguments.length === 2 || arguments.length === 3) { if (Array.isArray(arguments[0])) { moduleManager.defineModule(AMDLoader.Utilities.generateAnonymousModule(), arguments[0], arguments[1], arguments[2], null); return; } } throw new Error('Unrecognized require call'); }
n/a
function RequireFunc() { if (arguments.length === 1) { if ((arguments[0] instanceof Object) && !Array.isArray(arguments[0])) { RequireFunc.config(arguments[0]); return; } if (typeof arguments[0] === 'string') { return moduleManager.synchronousRequire(arguments[0]); } } if (arguments.length === 2 || arguments.length === 3) { if (Array.isArray(arguments[0])) { moduleManager.defineModule(AMDLoader.Utilities.generateAnonymousModule(), arguments[0], arguments[1], arguments[2], null); return; } } throw new Error('Unrecognized require call'); }
n/a
config = function (params, shouldOverwrite) { if (shouldOverwrite === void 0) { shouldOverwrite = false; } moduleManager.configure(params, shouldOverwrite); }
...
jQuery: true
};
AMDLoader.DefineFunc = DefineFunc;
var RequireFunc = (function () {
function RequireFunc() {
if (arguments.length === 1) {
if ((arguments[0] instanceof Object) && !Array.isArray(arguments[0])) {
RequireFunc.config(arguments[0]);
return;
}
if (typeof arguments[0] === 'string') {
return moduleManager.synchronousRequire(arguments[0]);
}
}
if (arguments.length === 2 || arguments.length === 3) {
...
getBuildInfo = function () { return moduleManager.getBuildInfo(); }
...
RequireFunc.reset = function () {
moduleManager = new AMDLoader.ModuleManager(AMDLoader.scriptLoader, loaderAvailableTimestamp);
};
/**
* Non standard extension to fetch loader state for building purposes.
*/
RequireFunc.getBuildInfo = function () {
return moduleManager.getBuildInfo();
};
/**
* Non standard extension to fetch loader events
*/
RequireFunc.getStats = function () {
return moduleManager.getLoaderEvents();
};
...
getConfig = function () { return moduleManager.getConfig().getOptionsLiteral(); }
...
this._fs = nodeRequire('fs');
this._vm = nodeRequire('vm');
this._path = nodeRequire('path');
this._crypto = nodeRequire('crypto');
};
NodeScriptLoader.prototype.load = function (moduleManager, scriptSrc, callback, errorback) {
var _this = this;
var opts = moduleManager.getConfig().getOptionsLiteral();
var nodeRequire = (opts.nodeRequire || AMDLoader.global.nodeRequire);
var nodeInstrumenter = (opts.nodeInstrumenter || function (c) { return c; });
this._init(nodeRequire);
var recorder = moduleManager.getRecorder();
if (/^node\|/.test(scriptSrc)) {
var pieces = scriptSrc.split('|');
var moduleExports_1 = null;
...
getStats = function () { return moduleManager.getLoaderEvents(); }
n/a
nodeRequire = function (what) { moduleManager.getRecorder().record(AMDLoader.LoaderEventType.NodeBeginNativeRequire, what); try { return _nodeRequire(what); } finally { moduleManager.getRecorder().record(AMDLoader.LoaderEventType.NodeEndNativeRequire, what); } }
...
var linkNode = this.createLinkTag(name, cssUrl, externalCallback, externalErrorback);
this._insertLinkNode(linkNode);
};
return BrowserCSSLoader;
}());
var NodeCSSLoader = (function () {
function NodeCSSLoader() {
this.fs = require.nodeRequire('fs');
}
NodeCSSLoader.prototype.load = function (name, cssUrl, externalCallback, externalErrorback) {
var contents = this.fs.readFileSync(cssUrl, 'utf8');
// Remove BOM
if (contents.charCodeAt(0) === NodeCSSLoader.BOM_CHAR_CODE) {
contents = contents.substring(1);
}
...
reset = function () { moduleManager = new AMDLoader.ModuleManager(AMDLoader.scriptLoader, loaderAvailableTimestamp); }
...
modes.SignatureHelpProviderRegistry.onDidChange(this._update, this, this._disposables);
this._update();
}
EditorModeContext.prototype.dispose = function () {
this._disposables = lifecycle_1.dispose(this._disposables);
};
EditorModeContext.prototype.reset = function () {
this._langId.reset();
this._hasCompletionItemProvider.reset();
this._hasCodeActionsProvider.reset();
this._hasCodeLensProvider.reset();
this._hasDefinitionProvider.reset();
this._hasImplementationProvider.reset();
this._hasHoverProvider.reset();
this._hasDocumentHighlightProvider.reset();
...