improve sql bindings extension (#18757)

This commit is contained in:
Vasu Bhog
2022-03-17 11:37:37 -07:00
committed by GitHub
parent 80007a72cc
commit d063355b1a
10 changed files with 41 additions and 160 deletions

View File

@@ -7,7 +7,6 @@ declare module 'vscode-mssql' {
import * as vscode from 'vscode';
import { RequestType } from 'vscode-languageclient';
import { BindingType, GetAzureFunctionsResult } from 'sql-bindings';
/**
* Covers defining what the vscode-mssql extension exports to other extensions
@@ -41,11 +40,6 @@ declare module 'vscode-mssql' {
*/
readonly schemaCompare: ISchemaCompareService;
/**
* Service for accessing AzureFunctions functionality
*/
readonly azureFunctions: IAzureFunctionsService;
/**
* Prompts the user to select an existing connection or create a new one, and then returns the result
* @param ignoreFocusOut Whether the quickpick prompt ignores focus out (default false)
@@ -101,7 +95,7 @@ declare module 'vscode-mssql' {
* @param params The params to pass with the request
* @returns A promise object for when the request receives a response
*/
sendRequest<P, R, E, R0>(requestType: RequestType<P, R, E, R0>, params?: P): Promise<R>;
sendRequest<P, R, E, R0>(requestType: RequestType<P, R, E, R0>, params?: P): Promise<R>;
}
/**
@@ -302,24 +296,6 @@ declare module 'vscode-mssql' {
validateStreamingJob(packageFilePath: string, createStreamingJobTsql: string): Thenable<ValidateStreamingJobResult>;
}
export interface IAzureFunctionsService {
/**
* Adds a SQL Binding to a specified Azure function in a file
* @param bindingType Type of SQL Binding
* @param filePath Path of the file where the Azure Functions are
* @param functionName Name of the function where the SQL Binding is to be added
* @param objectName Name of Object for the SQL Query
* @param connectionStringSetting Setting for the connection string
*/
addSqlBinding(bindingType: BindingType, filePath: string, functionName: string, objectName: string, connectionStringSetting: string): Thenable<ResultStatus>;
/**
* Gets the names of the Azure functions in the file
* @param filePath Path of the file to get the Azure functions
* @returns array of names of Azure functions in the file
*/
getAzureFunctions(filePath: string): Thenable<GetAzureFunctionsResult>;
}
export const enum TaskExecutionMode {
execute = 0,
script = 1,