Feature/script execute (#563)

* added script as execute for stored procedures
This commit is contained in:
Leila Lali
2017-12-05 13:17:51 -08:00
committed by GitHub
parent 6f32221496
commit e7b76a6dec
14 changed files with 579 additions and 226 deletions

View File

@@ -42,16 +42,34 @@ namespace Microsoft.SqlTools.ServiceLayer.Scripting
/// </summary>
public event EventHandler<ScriptingProgressNotificationParams> ProgressNotification;
/// <summary>
/// Event raised when a scripting operation has resolved which database objects will be scripted.
/// </summary>
public event EventHandler<ScriptingPlanNotificationParams> PlanNotification;
protected virtual void SendCompletionNotificationEvent(ScriptingCompleteParams parameters)
{
this.SetCommonEventProperties(parameters);
this.CompleteNotification?.Invoke(this, parameters);
}
protected virtual void SendProgressNotificationEvent(ScriptingProgressNotificationParams parameters)
{
this.SetCommonEventProperties(parameters);
this.ProgressNotification?.Invoke(this, parameters);
}
protected virtual void SendPlanNotificationEvent(ScriptingPlanNotificationParams parameters)
{
this.SetCommonEventProperties(parameters);
this.PlanNotification?.Invoke(this, parameters);
}
protected virtual void SetCommonEventProperties(ScriptingEventParams parameters)
{
parameters.OperationId = this.OperationId;
}
protected string GetServerNameFromLiveInstance(string connectionString)
{
string serverName = null;