Feature/batch line info (#56)

* inital pipe of line numbers and getting text from workspace services

* tests compile

* Fixed bug regarding tests using connections on mac

* updated tests

* fixed workspace service and fixed tests

* integrated feedback
This commit is contained in:
Anthony Dresser
2016-09-22 17:58:45 -07:00
committed by GitHub
parent 93a75f1ff4
commit f22c8a7283
16 changed files with 321 additions and 93 deletions

View File

@@ -20,6 +20,11 @@ namespace Microsoft.SqlTools.ServiceLayer.QueryExecution.Contracts
/// </summary>
public int Id { get; set; }
/// <summary>
/// The selection from the file for this batch
/// </summary>
public SelectionData Selection { get; set; }
/// <summary>
/// Any messages that came back from the server during execution of the batch
/// </summary>

View File

@@ -7,15 +7,30 @@ using Microsoft.SqlTools.ServiceLayer.Hosting.Protocol.Contracts;
namespace Microsoft.SqlTools.ServiceLayer.QueryExecution.Contracts
{
/// <summary>
/// Container class for a selection range from file
/// </summary>
public class SelectionData {
public int StartLine { get; set; }
public int StartColumn { get; set; }
public int EndLine { get; set; }
public int EndColumn { get; set; }
public SelectionData(int startLine, int startColumn, int endLine, int endColumn) {
StartLine = startLine;
StartColumn = startColumn;
EndLine = endLine;
EndColumn = endColumn;
}
}
/// <summary>
/// Parameters for the query execute request
/// </summary>
public class QueryExecuteParams
{
/// <summary>
/// The text of the query to execute
/// The selection from the document
/// </summary>
public string QueryText { get; set; }
public SelectionData QuerySelection { get; set; }
/// <summary>
/// URI for the editor that is asking for the query execute