mirror of
https://github.com/ckaczor/sqltoolsservice.git
synced 2026-01-14 01:25:40 -05:00
Stubbing out query execution settings
Adding a setting for batch separator. Very small refactor to WorkspaceService that will create the basic settings upon construction of the object.
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Microsoft.SqlTools.ServiceLayer.SqlContext
|
||||
{
|
||||
public class QueryExecutionSettings
|
||||
{
|
||||
private const string DefaultBatchSeparator = "GO";
|
||||
|
||||
private string batchSeparator;
|
||||
|
||||
public string BatchSeparator
|
||||
{
|
||||
get { return batchSeparator ?? DefaultBatchSeparator; }
|
||||
set { batchSeparator = value; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Update the current settings with the new settings
|
||||
/// </summary>
|
||||
/// <param name="newSettings">The new settings</param>
|
||||
public void Update(QueryExecutionSettings newSettings)
|
||||
{
|
||||
BatchSeparator = newSettings.BatchSeparator;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user