Adds build connection info feature (#2192)

* connection string

* formatting

* change serailize reponse type to match connect params

* add connection string serialization

* readd the connection string to the connection widget

* format

* remove unnecessary change

* update serializer to require provider

* update name of function

* fix function name

* bump dataprotocol and sqltools

* revert unnecessary change

* remove more unnecessary chagnes

* bump sqltoolsserivce

* adde configuration for auto parsing the clipboard
This commit is contained in:
Anthony Dresser
2018-08-20 11:50:16 -07:00
committed by Karl Burtram
parent 21c4429c6e
commit 033c8cb8b1
14 changed files with 98 additions and 23 deletions

View File

@@ -11,6 +11,7 @@ import { IMainContext } from 'vs/workbench/api/node/extHost.protocol';
import { Disposable } from 'vs/workbench/api/node/extHostTypes';
import { SqlMainContext, MainThreadDataProtocolShape, ExtHostDataProtocolShape } from 'sql/workbench/api/node/sqlExtHost.protocol';
import { DataProviderType } from 'sql/workbench/api/common/sqlExtHostTypes';
import { TPromise } from 'vs/base/common/winjs.base';
export class ExtHostDataProtocol extends ExtHostDataProtocolShape {
@@ -185,6 +186,15 @@ export class ExtHostDataProtocol extends ExtHostDataProtocolShape {
return this._resolveProvider<sqlops.ConnectionProvider>(handle).getConnectionString(connectionUri, includePassword);
}
$buildConnectionInfo(handle: number, connectionString: string): Thenable<sqlops.ConnectionInfo> {
let provider = this._resolveProvider<sqlops.ConnectionProvider>(handle);
if (provider.buildConnectionInfo) {
return provider.buildConnectionInfo(connectionString);
} else {
return TPromise.as(undefined);
}
}
$rebuildIntelliSenseCache(handle: number, connectionUri: string): Thenable<void> {
return this._resolveProvider<sqlops.ConnectionProvider>(handle).rebuildIntelliSenseCache(connectionUri);
}
@@ -617,7 +627,7 @@ export class ExtHostDataProtocol extends ExtHostDataProtocolShape {
/**
* Get Agent Proxies list
*/
$getProxies(handle: number, ownerUri: string): Thenable<sqlops.AgentProxiesResult> {
$getProxies(handle: number, ownerUri: string): Thenable<sqlops.AgentProxiesResult> {
return this._resolveProvider<sqlops.AgentServicesProvider>(handle).getProxies(ownerUri);
}