Move protocol client out (#643)

* close

* connection is working

* formatting

* adds all

* formatting

* formatting and changing how features are initialized

* formatting

* changed named of typings file

* update

* updated to use dataprotocol npm

* formatting

* removed unneeded logging

* readd npm shrinkwrap

* still not working

* removed unnecessary codfe

* addressed comments

* readded azure resource provider

* fix capabilities cacheing

* added backwards capat for older protocol

* update shrinkwrap

* update shrinkwrap

* updated shrinkwrap

* fixed tests

* removed dead code

* remove dead code

* fix compile

* remove backcompat stuff

* change location of npm

* vbump sqltools

* merge master

* fix imports

* fix build breaks

* update for sqlops

* update yarn dependencies
This commit is contained in:
Anthony Dresser
2018-02-20 13:38:16 -08:00
committed by GitHub
parent 8a9ee40524
commit 8570910a43
159 changed files with 4421 additions and 7180 deletions

View File

@@ -12,17 +12,17 @@ import { MessageType } from 'vs/base/browser/ui/inputbox/inputBox';
import { IContextViewService } from 'vs/platform/contextview/browser/contextView';
import { InputBox } from 'sql/base/browser/ui/inputBox/inputBox';
import * as types from 'vs/base/common/types';
import data = require('data');
import * as sqlops from 'sqlops';
import { localize } from 'vs/nls';
import { ServiceOptionType } from 'sql/workbench/api/common/sqlExtHostTypes';
export interface IOptionElement {
optionWidget: any;
option: data.ServiceOption;
option: sqlops.ServiceOption;
optionValue: any;
}
export function createOptionElement(option: data.ServiceOption, rowContainer: Builder, options: { [name: string]: any },
export function createOptionElement(option: sqlops.ServiceOption, rowContainer: Builder, options: { [name: string]: any },
optionsMap: { [optionName: string]: IOptionElement }, contextViewService: IContextViewService, onFocus: (name) => void): void {
let possibleInputs: string[] = [];
let optionValue = this.getOptionValueAndCategoryValues(option, options, possibleInputs);
@@ -67,8 +67,7 @@ export function createOptionElement(option: data.ServiceOption, rowContainer: Bu
inputElement.onfocus = () => onFocus(option.name);
}
export function getOptionValueAndCategoryValues(option: data.ServiceOption, options: { [optionName: string]: any }, possibleInputs: string[]): any {
export function getOptionValueAndCategoryValues(option: sqlops.ServiceOption, options: { [optionName: string]: any }, possibleInputs: string[]): any {
var optionValue = option.defaultValue;
if (options[option.name]) {
// if the value type is boolean, the option value can be either boolean or string
@@ -160,8 +159,8 @@ export function findElement(container: Builder, className: string): HTMLElement
return elementBuilder.getHTMLElement();
}
export function groupOptionsByCategory(options: data.ServiceOption[]): { [category: string]: data.ServiceOption[] } {
var connectionOptionsMap: { [category: string]: data.ServiceOption[] } = {};
export function groupOptionsByCategory(options: sqlops.ServiceOption[]): { [category: string]: sqlops.ServiceOption[] } {
var connectionOptionsMap: { [category: string]: sqlops.ServiceOption[] } = {};
options.forEach(option => {
var groupName = option.groupName;
if (groupName === null || groupName === undefined) {