mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-20 17:22:51 -05:00
* removes more builder references * remove builder from profiler * formatting * fix profiler dailog * remove builder from oatuhdialog * remove the rest of builder references * formatting * add more strict null checks to base * enable strict tslint rules * fix formatting * fix compile error * fix the rest of the hygeny issues and add pipeline step * fix pipeline files
38 lines
1.3 KiB
TypeScript
38 lines
1.3 KiB
TypeScript
/*---------------------------------------------------------------------------------------------
|
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
*--------------------------------------------------------------------------------------------*/
|
|
'use strict';
|
|
|
|
import * as vscode from 'vscode';
|
|
import * as azdata from 'azdata';
|
|
import { ApiWrapper } from './apiWrapper';
|
|
import { CreateSessionDialog } from './dialogs/profilerCreateSessionDialog';
|
|
|
|
/**
|
|
* The main controller class that initializes the extension
|
|
*/
|
|
export class MainController {
|
|
protected _apiWrapper: ApiWrapper;
|
|
protected _context: vscode.ExtensionContext;
|
|
|
|
// PUBLIC METHODS
|
|
public constructor(context: vscode.ExtensionContext, apiWrapper?: ApiWrapper) {
|
|
this._apiWrapper = apiWrapper || new ApiWrapper();
|
|
this._context = context;
|
|
}
|
|
|
|
/**
|
|
* Deactivates the extension
|
|
*/
|
|
public deactivate(): void {
|
|
}
|
|
|
|
public activate(): void {
|
|
vscode.commands.registerCommand('profiler.openCreateSessionDialog', (ownerUri: string, providerType: string, templates: Array<azdata.ProfilerSessionTemplate>) => {
|
|
let dialog = new CreateSessionDialog(ownerUri, providerType, templates);
|
|
dialog.showDialog();
|
|
});
|
|
}
|
|
}
|