File tree Expand file tree Collapse file tree 1 file changed +54
-0
lines changed
src/PowerShellEditorServices.Protocol/LanguageServer Expand file tree Collapse file tree 1 file changed +54
-0
lines changed Original file line number Diff line number Diff line change
1
+ //
2
+ // Copyright (c) Microsoft. All rights reserved.
3
+ // Licensed under the MIT license. See LICENSE file in the project root for full license information.
4
+ //
5
+
6
+ using System . Collections ;
7
+ using Microsoft . PowerShell . EditorServices . Protocol . MessageProtocol ;
8
+ using System . Collections . Generic ;
9
+
10
+ namespace Microsoft . PowerShell . EditorServices . Protocol . LanguageServer
11
+ {
12
+ /// <summary>
13
+ /// Class to encapsulate the request type.
14
+ /// </summary>
15
+ class FormattingScriptRegionRequest
16
+ {
17
+ public static readonly
18
+ RequestType < FormattingScriptRegionRequestParams , FormattingScriptRegionRequestResult > Type =
19
+ RequestType < FormattingScriptRegionRequestParams , FormattingScriptRegionRequestResult > . Create ( "powerShell/getFormattingScriptRegion" ) ;
20
+ }
21
+
22
+ /// <summary>
23
+ /// Class to encapsulate the request parameters.
24
+ /// </summary>
25
+ class FormattingScriptRegionRequestParams
26
+ {
27
+ /// <summary>
28
+ /// Path of the file for which the markers are requested.
29
+ /// </summary>
30
+ public string fileUri ;
31
+
32
+ /// <summary>
33
+ /// Hint character
34
+ /// </summary>
35
+ public string character ;
36
+
37
+ /// <summary>
38
+ /// Character position
39
+ /// </summary>
40
+ public FilePosition filePosition ;
41
+ }
42
+
43
+ /// <summary>
44
+ /// Class to encapsulate the result of marker request.
45
+ /// </summary>
46
+ class FormattingScriptRegionRequestResult
47
+ {
48
+ /// <summary>
49
+ /// A region in the script that encapsulates the given character/position which is suitable for
50
+ /// for formatting
51
+ /// </summary>
52
+ public ScriptRegion scriptRegion ;
53
+ }
54
+ }
You can’t perform that action at this time.
0 commit comments