From 275d389f8a71b4999e147aef8aa47cc2cf915a11 Mon Sep 17 00:00:00 2001 From: Adam Driscoll Date: Tue, 21 Jul 2026 21:35:40 -0500 Subject: [PATCH] Add flexible VS Code automation API bridge --- HostInjection/Generated/VSCodeApi.g.cs | 8233 +++++++++++++++++ HostInjection/PowerShellProTools.VSCode.psm1 | 8 +- HostInjection/VSCodeApiProxy.cs | 482 + vscode/powershellprotools/.vscode/tasks.json | 14 +- vscode/powershellprotools/package-lock.json | 340 +- vscode/powershellprotools/package.json | 9 +- .../scripts/generate-vscode-api.js | 444 + vscode/powershellprotools/src/extension.ts | 2 +- .../src/generated/vscodeApiMetadata.ts | 1227 +++ .../src/services/vscodeApiDispatcher.ts | 253 + .../src/services/vscodeService.ts | 42 +- vscode/vscode.build.ps1 | 49 +- 12 files changed, 10829 insertions(+), 274 deletions(-) create mode 100644 HostInjection/Generated/VSCodeApi.g.cs create mode 100644 HostInjection/VSCodeApiProxy.cs create mode 100644 vscode/powershellprotools/scripts/generate-vscode-api.js create mode 100644 vscode/powershellprotools/src/generated/vscodeApiMetadata.ts create mode 100644 vscode/powershellprotools/src/services/vscodeApiDispatcher.ts diff --git a/HostInjection/Generated/VSCodeApi.g.cs b/HostInjection/Generated/VSCodeApi.g.cs new file mode 100644 index 0000000..faf6cba --- /dev/null +++ b/HostInjection/Generated/VSCodeApi.g.cs @@ -0,0 +1,8233 @@ +// + +namespace PowerShellToolsPro.Cmdlets.VSCode + +{ + + public sealed class VSCodeApi : VSCodeObject + { + internal VSCodeApi(VSCodeProxyClient client) + : base(client, VSCodeProxyClient.Path()) + { + commands = new VSCodecommands(client, VSCodeProxyClient.Path("commands")); + comments = new VSCodecomments(client, VSCodeProxyClient.Path("comments")); + debug = new VSCodedebug(client, VSCodeProxyClient.Path("debug")); + env = new VSCodeenv(client, VSCodeProxyClient.Path("env")); + extensions = new VSCodeextensions(client, VSCodeProxyClient.Path("extensions")); + languages = new VSCodelanguages(client, VSCodeProxyClient.Path("languages")); + scm = new VSCodescm(client, VSCodeProxyClient.Path("scm")); + tasks = new VSCodetasks(client, VSCodeProxyClient.Path("tasks")); + window = new VSCodewindow(client, VSCodeProxyClient.Path("window")); + workspace = new VSCodeworkspace(client, VSCodeProxyClient.Path("workspace")); + Breakpoint = new VSCodeBreakpointConstructor(client, VSCodeProxyClient.Path("Breakpoint")); + CallHierarchyIncomingCall = new VSCodeCallHierarchyIncomingCallConstructor(client, VSCodeProxyClient.Path("CallHierarchyIncomingCall")); + CallHierarchyItem = new VSCodeCallHierarchyItemConstructor(client, VSCodeProxyClient.Path("CallHierarchyItem")); + CallHierarchyOutgoingCall = new VSCodeCallHierarchyOutgoingCallConstructor(client, VSCodeProxyClient.Path("CallHierarchyOutgoingCall")); + CancellationTokenSource = new VSCodeCancellationTokenSourceConstructor(client, VSCodeProxyClient.Path("CancellationTokenSource")); + CodeAction = new VSCodeCodeActionConstructor(client, VSCodeProxyClient.Path("CodeAction")); + CodeActionKind = new VSCodeCodeActionKindConstructor(client, VSCodeProxyClient.Path("CodeActionKind")); + CodeLens = new VSCodeCodeLensConstructor(client, VSCodeProxyClient.Path("CodeLens")); + Color = new VSCodeColorConstructor(client, VSCodeProxyClient.Path("Color")); + ColorInformation = new VSCodeColorInformationConstructor(client, VSCodeProxyClient.Path("ColorInformation")); + ColorPresentation = new VSCodeColorPresentationConstructor(client, VSCodeProxyClient.Path("ColorPresentation")); + CompletionItem = new VSCodeCompletionItemConstructor(client, VSCodeProxyClient.Path("CompletionItem")); + CompletionList = new VSCodeCompletionListConstructor(client, VSCodeProxyClient.Path("CompletionList")); + CustomExecution = new VSCodeCustomExecutionConstructor(client, VSCodeProxyClient.Path("CustomExecution")); + DebugAdapterExecutable = new VSCodeDebugAdapterExecutableConstructor(client, VSCodeProxyClient.Path("DebugAdapterExecutable")); + DebugAdapterInlineImplementation = new VSCodeDebugAdapterInlineImplementationConstructor(client, VSCodeProxyClient.Path("DebugAdapterInlineImplementation")); + DebugAdapterServer = new VSCodeDebugAdapterServerConstructor(client, VSCodeProxyClient.Path("DebugAdapterServer")); + Diagnostic = new VSCodeDiagnosticConstructor(client, VSCodeProxyClient.Path("Diagnostic")); + DiagnosticRelatedInformation = new VSCodeDiagnosticRelatedInformationConstructor(client, VSCodeProxyClient.Path("DiagnosticRelatedInformation")); + Disposable = new VSCodeDisposableConstructor(client, VSCodeProxyClient.Path("Disposable")); + DocumentHighlight = new VSCodeDocumentHighlightConstructor(client, VSCodeProxyClient.Path("DocumentHighlight")); + DocumentLink = new VSCodeDocumentLinkConstructor(client, VSCodeProxyClient.Path("DocumentLink")); + DocumentSymbol = new VSCodeDocumentSymbolConstructor(client, VSCodeProxyClient.Path("DocumentSymbol")); + EvaluatableExpression = new VSCodeEvaluatableExpressionConstructor(client, VSCodeProxyClient.Path("EvaluatableExpression")); + EventEmitter = new VSCodeEventEmitterConstructor(client, VSCodeProxyClient.Path("EventEmitter")); + FileSystemError = new VSCodeFileSystemErrorConstructor(client, VSCodeProxyClient.Path("FileSystemError")); + FoldingRange = new VSCodeFoldingRangeConstructor(client, VSCodeProxyClient.Path("FoldingRange")); + FunctionBreakpoint = new VSCodeFunctionBreakpointConstructor(client, VSCodeProxyClient.Path("FunctionBreakpoint")); + Hover = new VSCodeHoverConstructor(client, VSCodeProxyClient.Path("Hover")); + Location = new VSCodeLocationConstructor(client, VSCodeProxyClient.Path("Location")); + MarkdownString = new VSCodeMarkdownStringConstructor(client, VSCodeProxyClient.Path("MarkdownString")); + ParameterInformation = new VSCodeParameterInformationConstructor(client, VSCodeProxyClient.Path("ParameterInformation")); + Position = new VSCodePositionConstructor(client, VSCodeProxyClient.Path("Position")); + ProcessExecution = new VSCodeProcessExecutionConstructor(client, VSCodeProxyClient.Path("ProcessExecution")); + QuickInputButtons = new VSCodeQuickInputButtonsConstructor(client, VSCodeProxyClient.Path("QuickInputButtons")); + Range = new VSCodeRangeConstructor(client, VSCodeProxyClient.Path("Range")); + RelativePattern = new VSCodeRelativePatternConstructor(client, VSCodeProxyClient.Path("RelativePattern")); + Selection = new VSCodeSelectionConstructor(client, VSCodeProxyClient.Path("Selection")); + SelectionRange = new VSCodeSelectionRangeConstructor(client, VSCodeProxyClient.Path("SelectionRange")); + SemanticTokens = new VSCodeSemanticTokensConstructor(client, VSCodeProxyClient.Path("SemanticTokens")); + SemanticTokensBuilder = new VSCodeSemanticTokensBuilderConstructor(client, VSCodeProxyClient.Path("SemanticTokensBuilder")); + SemanticTokensEdit = new VSCodeSemanticTokensEditConstructor(client, VSCodeProxyClient.Path("SemanticTokensEdit")); + SemanticTokensEdits = new VSCodeSemanticTokensEditsConstructor(client, VSCodeProxyClient.Path("SemanticTokensEdits")); + SemanticTokensLegend = new VSCodeSemanticTokensLegendConstructor(client, VSCodeProxyClient.Path("SemanticTokensLegend")); + ShellExecution = new VSCodeShellExecutionConstructor(client, VSCodeProxyClient.Path("ShellExecution")); + SignatureHelp = new VSCodeSignatureHelpConstructor(client, VSCodeProxyClient.Path("SignatureHelp")); + SignatureInformation = new VSCodeSignatureInformationConstructor(client, VSCodeProxyClient.Path("SignatureInformation")); + SnippetString = new VSCodeSnippetStringConstructor(client, VSCodeProxyClient.Path("SnippetString")); + SourceBreakpoint = new VSCodeSourceBreakpointConstructor(client, VSCodeProxyClient.Path("SourceBreakpoint")); + SymbolInformation = new VSCodeSymbolInformationConstructor(client, VSCodeProxyClient.Path("SymbolInformation")); + Task = new VSCodeTaskConstructor(client, VSCodeProxyClient.Path("Task")); + TaskGroup = new VSCodeTaskGroupConstructor(client, VSCodeProxyClient.Path("TaskGroup")); + TextEdit = new VSCodeTextEditConstructor(client, VSCodeProxyClient.Path("TextEdit")); + ThemeColor = new VSCodeThemeColorConstructor(client, VSCodeProxyClient.Path("ThemeColor")); + ThemeIcon = new VSCodeThemeIconConstructor(client, VSCodeProxyClient.Path("ThemeIcon")); + TreeItem = new VSCodeTreeItemConstructor(client, VSCodeProxyClient.Path("TreeItem")); + Uri = new VSCodeUriConstructor(client, VSCodeProxyClient.Path("Uri")); + WorkspaceEdit = new VSCodeWorkspaceEditConstructor(client, VSCodeProxyClient.Path("WorkspaceEdit")); + } + + public VSCodecommands commands { get; } + + public VSCodecomments comments { get; } + + public VSCodedebug debug { get; } + + public VSCodeenv env { get; } + + public VSCodeextensions extensions { get; } + + public VSCodelanguages languages { get; } + + public VSCodescm scm { get; } + + public VSCodetasks tasks { get; } + + public VSCodewindow window { get; } + + public VSCodeworkspace workspace { get; } + + public VSCodeBreakpointConstructor Breakpoint { get; } + + public VSCodeCallHierarchyIncomingCallConstructor CallHierarchyIncomingCall { get; } + + public VSCodeCallHierarchyItemConstructor CallHierarchyItem { get; } + + public VSCodeCallHierarchyOutgoingCallConstructor CallHierarchyOutgoingCall { get; } + + public VSCodeCancellationTokenSourceConstructor CancellationTokenSource { get; } + + public VSCodeCodeActionConstructor CodeAction { get; } + + public VSCodeCodeActionKindConstructor CodeActionKind { get; } + + public VSCodeCodeLensConstructor CodeLens { get; } + + public VSCodeColorConstructor Color { get; } + + public VSCodeColorInformationConstructor ColorInformation { get; } + + public VSCodeColorPresentationConstructor ColorPresentation { get; } + + public VSCodeCompletionItemConstructor CompletionItem { get; } + + public VSCodeCompletionListConstructor CompletionList { get; } + + public VSCodeCustomExecutionConstructor CustomExecution { get; } + + public VSCodeDebugAdapterExecutableConstructor DebugAdapterExecutable { get; } + + public VSCodeDebugAdapterInlineImplementationConstructor DebugAdapterInlineImplementation { get; } + + public VSCodeDebugAdapterServerConstructor DebugAdapterServer { get; } + + public VSCodeDiagnosticConstructor Diagnostic { get; } + + public VSCodeDiagnosticRelatedInformationConstructor DiagnosticRelatedInformation { get; } + + public VSCodeDisposableConstructor Disposable { get; } + + public VSCodeDocumentHighlightConstructor DocumentHighlight { get; } + + public VSCodeDocumentLinkConstructor DocumentLink { get; } + + public VSCodeDocumentSymbolConstructor DocumentSymbol { get; } + + public VSCodeEvaluatableExpressionConstructor EvaluatableExpression { get; } + + public VSCodeEventEmitterConstructor EventEmitter { get; } + + public VSCodeFileSystemErrorConstructor FileSystemError { get; } + + public VSCodeFoldingRangeConstructor FoldingRange { get; } + + public VSCodeFunctionBreakpointConstructor FunctionBreakpoint { get; } + + public VSCodeHoverConstructor Hover { get; } + + public VSCodeLocationConstructor Location { get; } + + public VSCodeMarkdownStringConstructor MarkdownString { get; } + + public VSCodeParameterInformationConstructor ParameterInformation { get; } + + public VSCodePositionConstructor Position { get; } + + public VSCodeProcessExecutionConstructor ProcessExecution { get; } + + public VSCodeQuickInputButtonsConstructor QuickInputButtons { get; } + + public VSCodeRangeConstructor Range { get; } + + public VSCodeRelativePatternConstructor RelativePattern { get; } + + public VSCodeSelectionConstructor Selection { get; } + + public VSCodeSelectionRangeConstructor SelectionRange { get; } + + public VSCodeSemanticTokensConstructor SemanticTokens { get; } + + public VSCodeSemanticTokensBuilderConstructor SemanticTokensBuilder { get; } + + public VSCodeSemanticTokensEditConstructor SemanticTokensEdit { get; } + + public VSCodeSemanticTokensEditsConstructor SemanticTokensEdits { get; } + + public VSCodeSemanticTokensLegendConstructor SemanticTokensLegend { get; } + + public VSCodeShellExecutionConstructor ShellExecution { get; } + + public VSCodeSignatureHelpConstructor SignatureHelp { get; } + + public VSCodeSignatureInformationConstructor SignatureInformation { get; } + + public VSCodeSnippetStringConstructor SnippetString { get; } + + public VSCodeSourceBreakpointConstructor SourceBreakpoint { get; } + + public VSCodeSymbolInformationConstructor SymbolInformation { get; } + + public VSCodeTaskConstructor Task { get; } + + public VSCodeTaskGroupConstructor TaskGroup { get; } + + public VSCodeTextEditConstructor TextEdit { get; } + + public VSCodeThemeColorConstructor ThemeColor { get; } + + public VSCodeThemeIconConstructor ThemeIcon { get; } + + public VSCodeTreeItemConstructor TreeItem { get; } + + public VSCodeUriConstructor Uri { get; } + + public VSCodeWorkspaceEditConstructor WorkspaceEdit { get; } + } + + + + public enum VSCodeColorThemeKind + { + Light = 1, + Dark = 2, + HighContrast = 3, + } + + public enum VSCodeCommentMode + { + Editing = 0, + Preview = 1, + } + + public enum VSCodeCommentThreadCollapsibleState + { + Collapsed = 0, + Expanded = 1, + } + + public enum VSCodeCompletionItemKind + { + Text = 0, + Method = 1, + Function = 2, + Constructor = 3, + Field = 4, + Variable = 5, + Class = 6, + Interface = 7, + Module = 8, + Property = 9, + Unit = 10, + Value = 11, + Enum = 12, + Keyword = 13, + Snippet = 14, + Color = 15, + Reference = 17, + File = 16, + Folder = 18, + EnumMember = 19, + Constant = 20, + Struct = 21, + Event = 22, + Operator = 23, + TypeParameter = 24, + User = 25, + Issue = 26, + } + + public enum VSCodeCompletionItemTag + { + Deprecated = 1, + } + + public enum VSCodeCompletionTriggerKind + { + Invoke = 0, + TriggerCharacter = 1, + TriggerForIncompleteCompletions = 2, + } + + public enum VSCodeConfigurationTarget + { + Global = 1, + Workspace = 2, + WorkspaceFolder = 3, + } + + public enum VSCodeDebugConfigurationProviderTriggerKind + { + Initial = 1, + Dynamic = 2, + } + + public enum VSCodeDebugConsoleMode + { + Separate = 0, + MergeWithParent = 1, + } + + public enum VSCodeDecorationRangeBehavior + { + OpenOpen = 0, + ClosedClosed = 1, + OpenClosed = 2, + ClosedOpen = 3, + } + + public enum VSCodeDiagnosticSeverity + { + Error = 0, + Warning = 1, + Information = 2, + Hint = 3, + } + + public enum VSCodeDiagnosticTag + { + Unnecessary = 1, + Deprecated = 2, + } + + public enum VSCodeDocumentHighlightKind + { + Text = 0, + Read = 1, + Write = 2, + } + + public enum VSCodeEndOfLine + { + LF = 1, + CRLF = 2, + } + + public enum VSCodeEnvironmentVariableMutatorType + { + Replace = 1, + Append = 2, + Prepend = 3, + } + + public enum VSCodeExtensionKind + { + UI = 1, + Workspace = 2, + } + + public enum VSCodeFileChangeType + { + Changed = 1, + Created = 2, + Deleted = 3, + } + + public enum VSCodeFileType + { + Unknown = 0, + File = 1, + Directory = 2, + SymbolicLink = 64, + } + + public enum VSCodeFoldingRangeKind + { + Comment = 1, + Imports = 2, + Region = 3, + } + + public enum VSCodeIndentAction + { + None = 0, + Indent = 1, + IndentOutdent = 2, + Outdent = 3, + } + + public enum VSCodeOverviewRulerLane + { + Left = 1, + Center = 2, + Right = 4, + Full = 7, + } + + public enum VSCodeProgressLocation + { + SourceControl = 1, + Window = 10, + Notification = 15, + } + + public enum VSCodeShellQuoting + { + Escape = 1, + Strong = 2, + Weak = 3, + } + + public enum VSCodeSignatureHelpTriggerKind + { + Invoke = 1, + TriggerCharacter = 2, + ContentChange = 3, + } + + public enum VSCodeStatusBarAlignment + { + Left = 1, + Right = 2, + } + + public enum VSCodeSymbolKind + { + File = 0, + Module = 1, + Namespace = 2, + Package = 3, + Class = 4, + Method = 5, + Property = 6, + Field = 7, + Constructor = 8, + Enum = 9, + Interface = 10, + Function = 11, + Variable = 12, + Constant = 13, + String = 14, + Number = 15, + Boolean = 16, + Array = 17, + Object = 18, + Key = 19, + Null = 20, + EnumMember = 21, + Struct = 22, + Event = 23, + Operator = 24, + TypeParameter = 25, + } + + public enum VSCodeSymbolTag + { + Deprecated = 1, + } + + public enum VSCodeTaskPanelKind + { + Shared = 1, + Dedicated = 2, + New = 3, + } + + public enum VSCodeTaskRevealKind + { + Always = 1, + Silent = 2, + Never = 3, + } + + public enum VSCodeTaskScope + { + Global = 1, + Workspace = 2, + } + + public enum VSCodeTextDocumentSaveReason + { + Manual = 1, + AfterDelay = 2, + FocusOut = 3, + } + + public enum VSCodeTextEditorCursorStyle + { + Line = 1, + Block = 2, + Underline = 3, + LineThin = 4, + BlockOutline = 5, + UnderlineThin = 6, + } + + public enum VSCodeTextEditorLineNumbersStyle + { + Off = 0, + On = 1, + Relative = 2, + } + + public enum VSCodeTextEditorRevealType + { + Default = 0, + InCenter = 1, + InCenterIfOutsideViewport = 2, + AtTop = 3, + } + + public enum VSCodeTextEditorSelectionChangeKind + { + Keyboard = 1, + Mouse = 2, + Command = 3, + } + + public enum VSCodeTreeItemCollapsibleState + { + None = 0, + Collapsed = 1, + Expanded = 2, + } + + public enum VSCodeUIKind + { + Desktop = 1, + Web = 2, + } + + public enum VSCodeViewColumn + { + Active = 0, + Beside = 1, + One = 1, + Two = 2, + Three = 3, + Four = 4, + Five = 5, + Six = 6, + Seven = 7, + Eight = 8, + Nine = 9, + } + + public sealed class VSCodecommands : VSCodeObject + { + internal VSCodecommands(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDisposable registerCommand(params object[] arguments) + { + return Invoke("registerCommand", arguments); + } + + public VSCodeDisposable registerTextEditorCommand(params object[] arguments) + { + return Invoke("registerTextEditorCommand", arguments); + } + + public object executeCommand(params object[] arguments) + { + return Invoke("executeCommand", arguments); + } + + public string[] getCommands(params object[] arguments) + { + return Invoke("getCommands", arguments); + } + } + + public sealed class VSCodecomments : VSCodeObject + { + internal VSCodecomments(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCommentController createCommentController(params object[] arguments) + { + return Invoke("createCommentController", arguments); + } + } + + public sealed class VSCodedebug : VSCodeObject + { + internal VSCodedebug(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugSession activeDebugSession + { + get { return Get("activeDebugSession"); } + } + + public VSCodeDebugConsole activeDebugConsole + { + get { return Get("activeDebugConsole"); } + } + + public VSCodeBreakpoint[] breakpoints + { + get { return Get("breakpoints"); } + } + + public VSCodeEvent onDidChangeActiveDebugSession + { + get { return Get("onDidChangeActiveDebugSession"); } + } + + public VSCodeEvent onDidStartDebugSession + { + get { return Get("onDidStartDebugSession"); } + } + + public VSCodeEvent onDidReceiveDebugSessionCustomEvent + { + get { return Get("onDidReceiveDebugSessionCustomEvent"); } + } + + public VSCodeEvent onDidTerminateDebugSession + { + get { return Get("onDidTerminateDebugSession"); } + } + + public VSCodeEvent onDidChangeBreakpoints + { + get { return Get("onDidChangeBreakpoints"); } + } + + public VSCodeDisposable registerDebugConfigurationProvider(params object[] arguments) + { + return Invoke("registerDebugConfigurationProvider", arguments); + } + + public VSCodeDisposable registerDebugAdapterDescriptorFactory(params object[] arguments) + { + return Invoke("registerDebugAdapterDescriptorFactory", arguments); + } + + public VSCodeDisposable registerDebugAdapterTrackerFactory(params object[] arguments) + { + return Invoke("registerDebugAdapterTrackerFactory", arguments); + } + + public bool startDebugging(params object[] arguments) + { + return Invoke("startDebugging", arguments); + } + + public void addBreakpoints(params object[] arguments) + { + Invoke("addBreakpoints", arguments); + } + + public void removeBreakpoints(params object[] arguments) + { + Invoke("removeBreakpoints", arguments); + } + + public VSCodeUri asDebugSourceUri(params object[] arguments) + { + return Invoke("asDebugSourceUri", arguments); + } + } + + public sealed class VSCodeenv : VSCodeObject + { + internal VSCodeenv(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string appName + { + get { return Get("appName"); } + } + + public string appRoot + { + get { return Get("appRoot"); } + } + + public string uriScheme + { + get { return Get("uriScheme"); } + } + + public string language + { + get { return Get("language"); } + } + + public VSCodeClipboard clipboard + { + get { return Get("clipboard"); } + } + + public string machineId + { + get { return Get("machineId"); } + } + + public string sessionId + { + get { return Get("sessionId"); } + } + + public string remoteName + { + get { return Get("remoteName"); } + } + + public string shell + { + get { return Get("shell"); } + } + + public VSCodeUIKind uiKind + { + get { return Get("uiKind"); } + } + + public bool openExternal(params object[] arguments) + { + return Invoke("openExternal", arguments); + } + + public VSCodeUri asExternalUri(params object[] arguments) + { + return Invoke("asExternalUri", arguments); + } + } + + public sealed class VSCodeextensions : VSCodeObject + { + internal VSCodeextensions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeExtension getExtension(params object[] arguments) + { + return Invoke("getExtension", arguments); + } + + public VSCodeExtension[] all + { + get { return Get("all"); } + } + + public VSCodeEvent onDidChange + { + get { return Get("onDidChange"); } + } + } + + public sealed class VSCodelanguages : VSCodeObject + { + internal VSCodelanguages(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string[] getLanguages(params object[] arguments) + { + return Invoke("getLanguages", arguments); + } + + public VSCodeTextDocument setTextDocumentLanguage(params object[] arguments) + { + return Invoke("setTextDocumentLanguage", arguments); + } + + public double match(params object[] arguments) + { + return Invoke("match", arguments); + } + + public VSCodeEvent onDidChangeDiagnostics + { + get { return Get("onDidChangeDiagnostics"); } + } + + public VSCodeDiagnostic[] getDiagnostics(params object[] arguments) + { + return Invoke("getDiagnostics", arguments); + } + + public VSCodeDiagnosticCollection createDiagnosticCollection(params object[] arguments) + { + return Invoke("createDiagnosticCollection", arguments); + } + + public VSCodeDisposable registerCompletionItemProvider(params object[] arguments) + { + return Invoke("registerCompletionItemProvider", arguments); + } + + public VSCodeDisposable registerCodeActionsProvider(params object[] arguments) + { + return Invoke("registerCodeActionsProvider", arguments); + } + + public VSCodeDisposable registerCodeLensProvider(params object[] arguments) + { + return Invoke("registerCodeLensProvider", arguments); + } + + public VSCodeDisposable registerDefinitionProvider(params object[] arguments) + { + return Invoke("registerDefinitionProvider", arguments); + } + + public VSCodeDisposable registerImplementationProvider(params object[] arguments) + { + return Invoke("registerImplementationProvider", arguments); + } + + public VSCodeDisposable registerTypeDefinitionProvider(params object[] arguments) + { + return Invoke("registerTypeDefinitionProvider", arguments); + } + + public VSCodeDisposable registerDeclarationProvider(params object[] arguments) + { + return Invoke("registerDeclarationProvider", arguments); + } + + public VSCodeDisposable registerHoverProvider(params object[] arguments) + { + return Invoke("registerHoverProvider", arguments); + } + + public VSCodeDisposable registerEvaluatableExpressionProvider(params object[] arguments) + { + return Invoke("registerEvaluatableExpressionProvider", arguments); + } + + public VSCodeDisposable registerDocumentHighlightProvider(params object[] arguments) + { + return Invoke("registerDocumentHighlightProvider", arguments); + } + + public VSCodeDisposable registerDocumentSymbolProvider(params object[] arguments) + { + return Invoke("registerDocumentSymbolProvider", arguments); + } + + public VSCodeDisposable registerWorkspaceSymbolProvider(params object[] arguments) + { + return Invoke("registerWorkspaceSymbolProvider", arguments); + } + + public VSCodeDisposable registerReferenceProvider(params object[] arguments) + { + return Invoke("registerReferenceProvider", arguments); + } + + public VSCodeDisposable registerRenameProvider(params object[] arguments) + { + return Invoke("registerRenameProvider", arguments); + } + + public VSCodeDisposable registerDocumentSemanticTokensProvider(params object[] arguments) + { + return Invoke("registerDocumentSemanticTokensProvider", arguments); + } + + public VSCodeDisposable registerDocumentRangeSemanticTokensProvider(params object[] arguments) + { + return Invoke("registerDocumentRangeSemanticTokensProvider", arguments); + } + + public VSCodeDisposable registerDocumentFormattingEditProvider(params object[] arguments) + { + return Invoke("registerDocumentFormattingEditProvider", arguments); + } + + public VSCodeDisposable registerDocumentRangeFormattingEditProvider(params object[] arguments) + { + return Invoke("registerDocumentRangeFormattingEditProvider", arguments); + } + + public VSCodeDisposable registerOnTypeFormattingEditProvider(params object[] arguments) + { + return Invoke("registerOnTypeFormattingEditProvider", arguments); + } + + public VSCodeDisposable registerSignatureHelpProvider(params object[] arguments) + { + return Invoke("registerSignatureHelpProvider", arguments); + } + + public VSCodeDisposable registerDocumentLinkProvider(params object[] arguments) + { + return Invoke("registerDocumentLinkProvider", arguments); + } + + public VSCodeDisposable registerColorProvider(params object[] arguments) + { + return Invoke("registerColorProvider", arguments); + } + + public VSCodeDisposable registerFoldingRangeProvider(params object[] arguments) + { + return Invoke("registerFoldingRangeProvider", arguments); + } + + public VSCodeDisposable registerSelectionRangeProvider(params object[] arguments) + { + return Invoke("registerSelectionRangeProvider", arguments); + } + + public VSCodeDisposable registerCallHierarchyProvider(params object[] arguments) + { + return Invoke("registerCallHierarchyProvider", arguments); + } + + public VSCodeDisposable setLanguageConfiguration(params object[] arguments) + { + return Invoke("setLanguageConfiguration", arguments); + } + } + + public sealed class VSCodescm : VSCodeObject + { + internal VSCodescm(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSourceControlInputBox inputBox + { + get { return Get("inputBox"); } + } + + public VSCodeSourceControl createSourceControl(params object[] arguments) + { + return Invoke("createSourceControl", arguments); + } + } + + public sealed class VSCodetasks : VSCodeObject + { + internal VSCodetasks(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDisposable registerTaskProvider(params object[] arguments) + { + return Invoke("registerTaskProvider", arguments); + } + + public VSCodeTask[] fetchTasks(params object[] arguments) + { + return Invoke("fetchTasks", arguments); + } + + public VSCodeTaskExecution executeTask(params object[] arguments) + { + return Invoke("executeTask", arguments); + } + + public VSCodeTaskExecution[] taskExecutions + { + get { return Get("taskExecutions"); } + } + + public VSCodeEvent onDidStartTask + { + get { return Get("onDidStartTask"); } + } + + public VSCodeEvent onDidEndTask + { + get { return Get("onDidEndTask"); } + } + + public VSCodeEvent onDidStartTaskProcess + { + get { return Get("onDidStartTaskProcess"); } + } + + public VSCodeEvent onDidEndTaskProcess + { + get { return Get("onDidEndTaskProcess"); } + } + } + + public sealed class VSCodewindow : VSCodeObject + { + internal VSCodewindow(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEditor activeTextEditor + { + get { return Get("activeTextEditor"); } + } + + public VSCodeTextEditor[] visibleTextEditors + { + get { return Get("visibleTextEditors"); } + } + + public VSCodeEvent onDidChangeActiveTextEditor + { + get { return Get("onDidChangeActiveTextEditor"); } + } + + public VSCodeEvent onDidChangeVisibleTextEditors + { + get { return Get("onDidChangeVisibleTextEditors"); } + } + + public VSCodeEvent onDidChangeTextEditorSelection + { + get { return Get("onDidChangeTextEditorSelection"); } + } + + public VSCodeEvent onDidChangeTextEditorVisibleRanges + { + get { return Get("onDidChangeTextEditorVisibleRanges"); } + } + + public VSCodeEvent onDidChangeTextEditorOptions + { + get { return Get("onDidChangeTextEditorOptions"); } + } + + public VSCodeEvent onDidChangeTextEditorViewColumn + { + get { return Get("onDidChangeTextEditorViewColumn"); } + } + + public VSCodeTerminal[] terminals + { + get { return Get("terminals"); } + } + + public VSCodeTerminal activeTerminal + { + get { return Get("activeTerminal"); } + } + + public VSCodeEvent onDidChangeActiveTerminal + { + get { return Get("onDidChangeActiveTerminal"); } + } + + public VSCodeEvent onDidOpenTerminal + { + get { return Get("onDidOpenTerminal"); } + } + + public VSCodeEvent onDidCloseTerminal + { + get { return Get("onDidCloseTerminal"); } + } + + public VSCodeWindowState state + { + get { return Get("state"); } + } + + public VSCodeEvent onDidChangeWindowState + { + get { return Get("onDidChangeWindowState"); } + } + + public VSCodeTextEditor showTextDocument(params object[] arguments) + { + return Invoke("showTextDocument", arguments); + } + + public VSCodeTextEditorDecorationType createTextEditorDecorationType(params object[] arguments) + { + return Invoke("createTextEditorDecorationType", arguments); + } + + public string showInformationMessage(params object[] arguments) + { + return Invoke("showInformationMessage", arguments); + } + + public string showWarningMessage(params object[] arguments) + { + return Invoke("showWarningMessage", arguments); + } + + public string showErrorMessage(params object[] arguments) + { + return Invoke("showErrorMessage", arguments); + } + + public string[] showQuickPick(params object[] arguments) + { + return Invoke("showQuickPick", arguments); + } + + public VSCodeWorkspaceFolder showWorkspaceFolderPick(params object[] arguments) + { + return Invoke("showWorkspaceFolderPick", arguments); + } + + public VSCodeUri[] showOpenDialog(params object[] arguments) + { + return Invoke("showOpenDialog", arguments); + } + + public VSCodeUri showSaveDialog(params object[] arguments) + { + return Invoke("showSaveDialog", arguments); + } + + public string showInputBox(params object[] arguments) + { + return Invoke("showInputBox", arguments); + } + + public VSCodeQuickPick createQuickPick(params object[] arguments) + { + return Invoke("createQuickPick", arguments); + } + + public VSCodeInputBox createInputBox(params object[] arguments) + { + return Invoke("createInputBox", arguments); + } + + public VSCodeOutputChannel createOutputChannel(params object[] arguments) + { + return Invoke("createOutputChannel", arguments); + } + + public VSCodeWebviewPanel createWebviewPanel(params object[] arguments) + { + return Invoke("createWebviewPanel", arguments); + } + + public VSCodeDisposable setStatusBarMessage(params object[] arguments) + { + return Invoke("setStatusBarMessage", arguments); + } + + public object withScmProgress(params object[] arguments) + { + return Invoke("withScmProgress", arguments); + } + + public object withProgress(params object[] arguments) + { + return Invoke("withProgress", arguments); + } + + public VSCodeStatusBarItem createStatusBarItem(params object[] arguments) + { + return Invoke("createStatusBarItem", arguments); + } + + public VSCodeTerminal createTerminal(params object[] arguments) + { + return Invoke("createTerminal", arguments); + } + + public VSCodeDisposable registerTreeDataProvider(params object[] arguments) + { + return Invoke("registerTreeDataProvider", arguments); + } + + public VSCodeTreeView createTreeView(params object[] arguments) + { + return Invoke("createTreeView", arguments); + } + + public VSCodeDisposable registerUriHandler(params object[] arguments) + { + return Invoke("registerUriHandler", arguments); + } + + public VSCodeDisposable registerWebviewPanelSerializer(params object[] arguments) + { + return Invoke("registerWebviewPanelSerializer", arguments); + } + + public VSCodeDisposable registerCustomEditorProvider(params object[] arguments) + { + return Invoke("registerCustomEditorProvider", arguments); + } + + public VSCodeColorTheme activeColorTheme + { + get { return Get("activeColorTheme"); } + } + + public VSCodeEvent onDidChangeActiveColorTheme + { + get { return Get("onDidChangeActiveColorTheme"); } + } + } + + public sealed class VSCodeworkspace : VSCodeObject + { + internal VSCodeworkspace(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFileSystem fs + { + get { return Get("fs"); } + } + + public string rootPath + { + get { return Get("rootPath"); } + } + + public VSCodeWorkspaceFolder[] workspaceFolders + { + get { return Get("workspaceFolders"); } + } + + public string name + { + get { return Get("name"); } + } + + public VSCodeUri workspaceFile + { + get { return Get("workspaceFile"); } + } + + public VSCodeEvent onDidChangeWorkspaceFolders + { + get { return Get("onDidChangeWorkspaceFolders"); } + } + + public VSCodeWorkspaceFolder getWorkspaceFolder(params object[] arguments) + { + return Invoke("getWorkspaceFolder", arguments); + } + + public string asRelativePath(params object[] arguments) + { + return Invoke("asRelativePath", arguments); + } + + public bool updateWorkspaceFolders(params object[] arguments) + { + return Invoke("updateWorkspaceFolders", arguments); + } + + public VSCodeFileSystemWatcher createFileSystemWatcher(params object[] arguments) + { + return Invoke("createFileSystemWatcher", arguments); + } + + public VSCodeUri[] findFiles(params object[] arguments) + { + return Invoke("findFiles", arguments); + } + + public bool saveAll(params object[] arguments) + { + return Invoke("saveAll", arguments); + } + + public bool applyEdit(params object[] arguments) + { + return Invoke("applyEdit", arguments); + } + + public VSCodeTextDocument[] textDocuments + { + get { return Get("textDocuments"); } + } + + public VSCodeTextDocument openTextDocument(params object[] arguments) + { + return Invoke("openTextDocument", arguments); + } + + public VSCodeDisposable registerTextDocumentContentProvider(params object[] arguments) + { + return Invoke("registerTextDocumentContentProvider", arguments); + } + + public VSCodeEvent onDidOpenTextDocument + { + get { return Get("onDidOpenTextDocument"); } + } + + public VSCodeEvent onDidCloseTextDocument + { + get { return Get("onDidCloseTextDocument"); } + } + + public VSCodeEvent onDidChangeTextDocument + { + get { return Get("onDidChangeTextDocument"); } + } + + public VSCodeEvent onWillSaveTextDocument + { + get { return Get("onWillSaveTextDocument"); } + } + + public VSCodeEvent onDidSaveTextDocument + { + get { return Get("onDidSaveTextDocument"); } + } + + public VSCodeEvent onWillCreateFiles + { + get { return Get("onWillCreateFiles"); } + } + + public VSCodeEvent onDidCreateFiles + { + get { return Get("onDidCreateFiles"); } + } + + public VSCodeEvent onWillDeleteFiles + { + get { return Get("onWillDeleteFiles"); } + } + + public VSCodeEvent onDidDeleteFiles + { + get { return Get("onDidDeleteFiles"); } + } + + public VSCodeEvent onWillRenameFiles + { + get { return Get("onWillRenameFiles"); } + } + + public VSCodeEvent onDidRenameFiles + { + get { return Get("onDidRenameFiles"); } + } + + public VSCodeWorkspaceConfiguration getConfiguration(params object[] arguments) + { + return Invoke("getConfiguration", arguments); + } + + public VSCodeEvent onDidChangeConfiguration + { + get { return Get("onDidChangeConfiguration"); } + } + + public VSCodeDisposable registerTaskProvider(params object[] arguments) + { + return Invoke("registerTaskProvider", arguments); + } + + public VSCodeDisposable registerFileSystemProvider(params object[] arguments) + { + return Invoke("registerFileSystemProvider", arguments); + } + } + + public sealed class VSCodeBreakpointsChangeEvent : VSCodeObject + { + internal VSCodeBreakpointsChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeBreakpoint[] added + { + get { return Get("added"); } + } + + public VSCodeBreakpoint[] removed + { + get { return Get("removed"); } + } + + public VSCodeBreakpoint[] changed + { + get { return Get("changed"); } + } + } + + public sealed class VSCodeCallHierarchyProvider : VSCodeObject + { + internal VSCodeCallHierarchyProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object prepareCallHierarchy(params object[] arguments) + { + return Invoke("prepareCallHierarchy", arguments); + } + + public VSCodeCallHierarchyIncomingCall[] provideCallHierarchyIncomingCalls(params object[] arguments) + { + return Invoke("provideCallHierarchyIncomingCalls", arguments); + } + + public VSCodeCallHierarchyOutgoingCall[] provideCallHierarchyOutgoingCalls(params object[] arguments) + { + return Invoke("provideCallHierarchyOutgoingCalls", arguments); + } + } + + public sealed class VSCodeCancellationToken : VSCodeObject + { + internal VSCodeCancellationToken(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool isCancellationRequested + { + get { return Get("isCancellationRequested"); } + } + + public VSCodeEvent onCancellationRequested + { + get { return Get("onCancellationRequested"); } + } + } + + public sealed class VSCodeClipboard : VSCodeObject + { + internal VSCodeClipboard(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string readText(params object[] arguments) + { + return Invoke("readText", arguments); + } + + public void writeText(params object[] arguments) + { + Invoke("writeText", arguments); + } + } + + public sealed class VSCodeCodeActionContext : VSCodeObject + { + internal VSCodeCodeActionContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDiagnostic[] diagnostics + { + get { return Get("diagnostics"); } + } + + public VSCodeCodeActionKind only + { + get { return Get("only"); } + } + } + + public sealed class VSCodeCodeActionProvider : VSCodeObject + { + internal VSCodeCodeActionProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] provideCodeActions(params object[] arguments) + { + return Invoke("provideCodeActions", arguments); + } + } + + public sealed class VSCodeCodeActionProviderMetadata : VSCodeObject + { + internal VSCodeCodeActionProviderMetadata(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCodeActionKind[] providedCodeActionKinds + { + get { return Get("providedCodeActionKinds"); } + } + } + + public sealed class VSCodeCodeLensProvider : VSCodeObject + { + internal VSCodeCodeLensProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidChangeCodeLenses + { + get { return Get("onDidChangeCodeLenses"); } + } + + public object[] provideCodeLenses(params object[] arguments) + { + return Invoke("provideCodeLenses", arguments); + } + + public object resolveCodeLens(params object[] arguments) + { + return Invoke("resolveCodeLens", arguments); + } + } + + public sealed class VSCodeColorTheme : VSCodeObject + { + internal VSCodeColorTheme(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeColorThemeKind kind + { + get { return Get("kind"); } + } + } + + public sealed class VSCodeCommand : VSCodeObject + { + internal VSCodeCommand(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string title + { + get { return Get("title"); } + } + + public string command + { + get { return Get("command"); } + } + + public string tooltip + { + get { return Get("tooltip"); } + } + + public object[] arguments + { + get { return Get("arguments"); } + } + } + + public sealed class VSCodeComment : VSCodeObject + { + internal VSCodeComment(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object body + { + get { return Get("body"); } + } + + public VSCodeCommentMode mode + { + get { return Get("mode"); } + } + + public VSCodeCommentAuthorInformation author + { + get { return Get("author"); } + } + + public string contextValue + { + get { return Get("contextValue"); } + } + + public VSCodeCommentReaction[] reactions + { + get { return Get("reactions"); } + } + + public string label + { + get { return Get("label"); } + } + } + + public sealed class VSCodeCommentAuthorInformation : VSCodeObject + { + internal VSCodeCommentAuthorInformation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public VSCodeUri iconPath + { + get { return Get("iconPath"); } + } + } + + public sealed class VSCodeCommentController : VSCodeObject + { + internal VSCodeCommentController(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public string label + { + get { return Get("label"); } + } + + public VSCodeCommentOptions options + { + get { return Get("options"); } + } + + public VSCodeCommentingRangeProvider commentingRangeProvider + { + get { return Get("commentingRangeProvider"); } + } + + public VSCodeCommentThread createCommentThread(params object[] arguments) + { + return Invoke("createCommentThread", arguments); + } + + public object reactionHandler + { + get { return Get("reactionHandler"); } + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeCommentingRangeProvider : VSCodeObject + { + internal VSCodeCommentingRangeProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange[] provideCommentingRanges(params object[] arguments) + { + return Invoke("provideCommentingRanges", arguments); + } + } + + public sealed class VSCodeCommentOptions : VSCodeObject + { + internal VSCodeCommentOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string prompt + { + get { return Get("prompt"); } + } + + public string placeHolder + { + get { return Get("placeHolder"); } + } + } + + public sealed class VSCodeCommentReaction : VSCodeObject + { + internal VSCodeCommentReaction(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + + public object iconPath + { + get { return Get("iconPath"); } + } + + public double count + { + get { return Get("count"); } + } + + public bool authorHasReacted + { + get { return Get("authorHasReacted"); } + } + } + + public sealed class VSCodeCommentReply : VSCodeObject + { + internal VSCodeCommentReply(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCommentThread thread + { + get { return Get("thread"); } + } + + public string text + { + get { return Get("text"); } + } + } + + public sealed class VSCodeCommentRule : VSCodeObject + { + internal VSCodeCommentRule(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string lineComment + { + get { return Get("lineComment"); } + } + + public object blockComment + { + get { return Get("blockComment"); } + } + } + + public sealed class VSCodeCommentThread : VSCodeObject + { + internal VSCodeCommentThread(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeComment[] comments + { + get { return Get("comments"); } + } + + public VSCodeCommentThreadCollapsibleState collapsibleState + { + get { return Get("collapsibleState"); } + } + + public string contextValue + { + get { return Get("contextValue"); } + } + + public string label + { + get { return Get("label"); } + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeCompletionContext : VSCodeObject + { + internal VSCodeCompletionContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCompletionTriggerKind triggerKind + { + get { return Get("triggerKind"); } + } + + public string triggerCharacter + { + get { return Get("triggerCharacter"); } + } + } + + public sealed class VSCodeCompletionItemProvider : VSCodeObject + { + internal VSCodeCompletionItemProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object provideCompletionItems(params object[] arguments) + { + return Invoke("provideCompletionItems", arguments); + } + + public object resolveCompletionItem(params object[] arguments) + { + return Invoke("resolveCompletionItem", arguments); + } + } + + public sealed class VSCodeConfigurationChangeEvent : VSCodeObject + { + internal VSCodeConfigurationChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool affectsConfiguration(params object[] arguments) + { + return Invoke("affectsConfiguration", arguments); + } + } + + public sealed class VSCodeCustomDocument : VSCodeObject + { + internal VSCodeCustomDocument(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeCustomDocumentBackup : VSCodeObject + { + internal VSCodeCustomDocumentBackup(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public void delete(params object[] arguments) + { + Invoke("delete", arguments); + } + } + + public sealed class VSCodeCustomDocumentBackupContext : VSCodeObject + { + internal VSCodeCustomDocumentBackupContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri destination + { + get { return Get("destination"); } + } + } + + public sealed class VSCodeCustomDocumentContentChangeEvent : VSCodeObject + { + internal VSCodeCustomDocumentContentChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object document + { + get { return Get("document"); } + } + } + + public sealed class VSCodeCustomDocumentEditEvent : VSCodeObject + { + internal VSCodeCustomDocumentEditEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object document + { + get { return Get("document"); } + } + + public object undo(params object[] arguments) + { + return Invoke("undo", arguments); + } + + public object redo(params object[] arguments) + { + return Invoke("redo", arguments); + } + + public string label + { + get { return Get("label"); } + } + } + + public sealed class VSCodeCustomDocumentOpenContext : VSCodeObject + { + internal VSCodeCustomDocumentOpenContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string backupId + { + get { return Get("backupId"); } + } + } + + public sealed class VSCodeCustomEditorProvider : VSCodeObject + { + internal VSCodeCustomEditorProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object onDidChangeCustomDocument + { + get { return Get("onDidChangeCustomDocument"); } + } + + public void saveCustomDocument(params object[] arguments) + { + Invoke("saveCustomDocument", arguments); + } + + public void saveCustomDocumentAs(params object[] arguments) + { + Invoke("saveCustomDocumentAs", arguments); + } + + public void revertCustomDocument(params object[] arguments) + { + Invoke("revertCustomDocument", arguments); + } + + public VSCodeCustomDocumentBackup backupCustomDocument(params object[] arguments) + { + return Invoke("backupCustomDocument", arguments); + } + } + + public sealed class VSCodeCustomReadonlyEditorProvider : VSCodeObject + { + internal VSCodeCustomReadonlyEditorProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object openCustomDocument(params object[] arguments) + { + return Invoke("openCustomDocument", arguments); + } + + public object resolveCustomEditor(params object[] arguments) + { + return Invoke("resolveCustomEditor", arguments); + } + } + + public sealed class VSCodeCustomTextEditorProvider : VSCodeObject + { + internal VSCodeCustomTextEditorProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object resolveCustomTextEditor(params object[] arguments) + { + return Invoke("resolveCustomTextEditor", arguments); + } + } + + public sealed class VSCodeDebugAdapter : VSCodeObject + { + internal VSCodeDebugAdapter(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidSendMessage + { + get { return Get("onDidSendMessage"); } + } + + public void handleMessage(params object[] arguments) + { + Invoke("handleMessage", arguments); + } + } + + public sealed class VSCodeDebugAdapterDescriptorFactory : VSCodeObject + { + internal VSCodeDebugAdapterDescriptorFactory(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object createDebugAdapterDescriptor(params object[] arguments) + { + return Invoke("createDebugAdapterDescriptor", arguments); + } + } + + public sealed class VSCodeDebugAdapterExecutableOptions : VSCodeObject + { + internal VSCodeDebugAdapterExecutableOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object env + { + get { return Get("env"); } + } + + public string cwd + { + get { return Get("cwd"); } + } + } + + public sealed class VSCodeDebugAdapterTracker : VSCodeObject + { + internal VSCodeDebugAdapterTracker(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void onWillStartSession(params object[] arguments) + { + Invoke("onWillStartSession", arguments); + } + + public void onWillReceiveMessage(params object[] arguments) + { + Invoke("onWillReceiveMessage", arguments); + } + + public void onDidSendMessage(params object[] arguments) + { + Invoke("onDidSendMessage", arguments); + } + + public void onWillStopSession(params object[] arguments) + { + Invoke("onWillStopSession", arguments); + } + + public void onError(params object[] arguments) + { + Invoke("onError", arguments); + } + + public void onExit(params object[] arguments) + { + Invoke("onExit", arguments); + } + } + + public sealed class VSCodeDebugAdapterTrackerFactory : VSCodeObject + { + internal VSCodeDebugAdapterTrackerFactory(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugAdapterTracker createDebugAdapterTracker(params object[] arguments) + { + return Invoke("createDebugAdapterTracker", arguments); + } + } + + public sealed class VSCodeDebugConfiguration : VSCodeObject + { + internal VSCodeDebugConfiguration(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string type + { + get { return Get("type"); } + } + + public string name + { + get { return Get("name"); } + } + + public string request + { + get { return Get("request"); } + } + } + + public sealed class VSCodeDebugConfigurationProvider : VSCodeObject + { + internal VSCodeDebugConfigurationProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugConfiguration[] provideDebugConfigurations(params object[] arguments) + { + return Invoke("provideDebugConfigurations", arguments); + } + + public VSCodeDebugConfiguration resolveDebugConfiguration(params object[] arguments) + { + return Invoke("resolveDebugConfiguration", arguments); + } + + public VSCodeDebugConfiguration resolveDebugConfigurationWithSubstitutedVariables(params object[] arguments) + { + return Invoke("resolveDebugConfigurationWithSubstitutedVariables", arguments); + } + } + + public sealed class VSCodeDebugConsole : VSCodeObject + { + internal VSCodeDebugConsole(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void append(params object[] arguments) + { + Invoke("append", arguments); + } + + public void appendLine(params object[] arguments) + { + Invoke("appendLine", arguments); + } + } + + public sealed class VSCodeDebugProtocolMessage : VSCodeObject + { + internal VSCodeDebugProtocolMessage(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeDebugProtocolSource : VSCodeObject + { + internal VSCodeDebugProtocolSource(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeDebugSession : VSCodeObject + { + internal VSCodeDebugSession(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public string type + { + get { return Get("type"); } + } + + public string name + { + get { return Get("name"); } + } + + public VSCodeWorkspaceFolder workspaceFolder + { + get { return Get("workspaceFolder"); } + } + + public VSCodeDebugConfiguration configuration + { + get { return Get("configuration"); } + } + + public object customRequest(params object[] arguments) + { + return Invoke("customRequest", arguments); + } + } + + public sealed class VSCodeDebugSessionCustomEvent : VSCodeObject + { + internal VSCodeDebugSessionCustomEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugSession session + { + get { return Get("session"); } + } + + public string @event + { + get { return Get("event"); } + } + + public object body + { + get { return Get("body"); } + } + } + + public sealed class VSCodeDebugSessionOptions : VSCodeObject + { + internal VSCodeDebugSessionOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugSession parentSession + { + get { return Get("parentSession"); } + } + + public VSCodeDebugConsoleMode consoleMode + { + get { return Get("consoleMode"); } + } + } + + public sealed class VSCodeDeclarationProvider : VSCodeObject + { + internal VSCodeDeclarationProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object provideDeclaration(params object[] arguments) + { + return Invoke("provideDeclaration", arguments); + } + } + + public sealed class VSCodeDecorationInstanceRenderOptions : VSCodeObject + { + internal VSCodeDecorationInstanceRenderOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeThemableDecorationInstanceRenderOptions light + { + get { return Get("light"); } + } + + public VSCodeThemableDecorationInstanceRenderOptions dark + { + get { return Get("dark"); } + } + } + + public sealed class VSCodeDecorationOptions : VSCodeObject + { + internal VSCodeDecorationOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public object hoverMessage + { + get { return Get("hoverMessage"); } + } + + public VSCodeDecorationInstanceRenderOptions renderOptions + { + get { return Get("renderOptions"); } + } + } + + public sealed class VSCodeDecorationRenderOptions : VSCodeObject + { + internal VSCodeDecorationRenderOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool isWholeLine + { + get { return Get("isWholeLine"); } + } + + public VSCodeDecorationRangeBehavior rangeBehavior + { + get { return Get("rangeBehavior"); } + } + + public VSCodeOverviewRulerLane overviewRulerLane + { + get { return Get("overviewRulerLane"); } + } + + public VSCodeThemableDecorationRenderOptions light + { + get { return Get("light"); } + } + + public VSCodeThemableDecorationRenderOptions dark + { + get { return Get("dark"); } + } + } + + public sealed class VSCodeDefinitionProvider : VSCodeObject + { + internal VSCodeDefinitionProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object provideDefinition(params object[] arguments) + { + return Invoke("provideDefinition", arguments); + } + } + + public sealed class VSCodeDiagnosticChangeEvent : VSCodeObject + { + internal VSCodeDiagnosticChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri[] uris + { + get { return Get("uris"); } + } + } + + public sealed class VSCodeDiagnosticCollection : VSCodeObject + { + internal VSCodeDiagnosticCollection(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public void set(params object[] arguments) + { + Invoke("set", arguments); + } + + public void delete(params object[] arguments) + { + Invoke("delete", arguments); + } + + public void clear(params object[] arguments) + { + Invoke("clear", arguments); + } + + public void forEach(params object[] arguments) + { + Invoke("forEach", arguments); + } + + public VSCodeDiagnostic[] get(params object[] arguments) + { + return Invoke("get", arguments); + } + + public bool has(params object[] arguments) + { + return Invoke("has", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeDocumentColorProvider : VSCodeObject + { + internal VSCodeDocumentColorProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeColorInformation[] provideDocumentColors(params object[] arguments) + { + return Invoke("provideDocumentColors", arguments); + } + + public VSCodeColorPresentation[] provideColorPresentations(params object[] arguments) + { + return Invoke("provideColorPresentations", arguments); + } + } + + public sealed class VSCodeDocumentFilter : VSCodeObject + { + internal VSCodeDocumentFilter(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string language + { + get { return Get("language"); } + } + + public string scheme + { + get { return Get("scheme"); } + } + + public object pattern + { + get { return Get("pattern"); } + } + } + + public sealed class VSCodeDocumentFormattingEditProvider : VSCodeObject + { + internal VSCodeDocumentFormattingEditProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEdit[] provideDocumentFormattingEdits(params object[] arguments) + { + return Invoke("provideDocumentFormattingEdits", arguments); + } + } + + public sealed class VSCodeDocumentHighlightProvider : VSCodeObject + { + internal VSCodeDocumentHighlightProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDocumentHighlight[] provideDocumentHighlights(params object[] arguments) + { + return Invoke("provideDocumentHighlights", arguments); + } + } + + public sealed class VSCodeDocumentLinkProvider : VSCodeObject + { + internal VSCodeDocumentLinkProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] provideDocumentLinks(params object[] arguments) + { + return Invoke("provideDocumentLinks", arguments); + } + + public object resolveDocumentLink(params object[] arguments) + { + return Invoke("resolveDocumentLink", arguments); + } + } + + public sealed class VSCodeDocumentRangeFormattingEditProvider : VSCodeObject + { + internal VSCodeDocumentRangeFormattingEditProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEdit[] provideDocumentRangeFormattingEdits(params object[] arguments) + { + return Invoke("provideDocumentRangeFormattingEdits", arguments); + } + } + + public sealed class VSCodeDocumentRangeSemanticTokensProvider : VSCodeObject + { + internal VSCodeDocumentRangeSemanticTokensProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSemanticTokens provideDocumentRangeSemanticTokens(params object[] arguments) + { + return Invoke("provideDocumentRangeSemanticTokens", arguments); + } + } + + public sealed class VSCodeDocumentSemanticTokensProvider : VSCodeObject + { + internal VSCodeDocumentSemanticTokensProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidChangeSemanticTokens + { + get { return Get("onDidChangeSemanticTokens"); } + } + + public VSCodeSemanticTokens provideDocumentSemanticTokens(params object[] arguments) + { + return Invoke("provideDocumentSemanticTokens", arguments); + } + + public object provideDocumentSemanticTokensEdits(params object[] arguments) + { + return Invoke("provideDocumentSemanticTokensEdits", arguments); + } + } + + public sealed class VSCodeDocumentSymbolProvider : VSCodeObject + { + internal VSCodeDocumentSymbolProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object provideDocumentSymbols(params object[] arguments) + { + return Invoke("provideDocumentSymbols", arguments); + } + } + + public sealed class VSCodeDocumentSymbolProviderMetadata : VSCodeObject + { + internal VSCodeDocumentSymbolProviderMetadata(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + } + + public sealed class VSCodeEnterAction : VSCodeObject + { + internal VSCodeEnterAction(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeIndentAction indentAction + { + get { return Get("indentAction"); } + } + + public string appendText + { + get { return Get("appendText"); } + } + + public double removeText + { + get { return Get("removeText"); } + } + } + + public sealed class VSCodeEnvironmentVariableCollection : VSCodeObject + { + internal VSCodeEnvironmentVariableCollection(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool persistent + { + get { return Get("persistent"); } + } + + public void replace(params object[] arguments) + { + Invoke("replace", arguments); + } + + public void append(params object[] arguments) + { + Invoke("append", arguments); + } + + public void prepend(params object[] arguments) + { + Invoke("prepend", arguments); + } + + public VSCodeEnvironmentVariableMutator get(params object[] arguments) + { + return Invoke("get", arguments); + } + + public void forEach(params object[] arguments) + { + Invoke("forEach", arguments); + } + + public void delete(params object[] arguments) + { + Invoke("delete", arguments); + } + + public void clear(params object[] arguments) + { + Invoke("clear", arguments); + } + } + + public sealed class VSCodeEnvironmentVariableMutator : VSCodeObject + { + internal VSCodeEnvironmentVariableMutator(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEnvironmentVariableMutatorType type + { + get { return Get("type"); } + } + + public string value + { + get { return Get("value"); } + } + } + + public sealed class VSCodeEvaluatableExpressionProvider : VSCodeObject + { + internal VSCodeEvaluatableExpressionProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvaluatableExpression provideEvaluatableExpression(params object[] arguments) + { + return Invoke("provideEvaluatableExpression", arguments); + } + } + + public sealed class VSCodeEvent : VSCodeObject + { + internal VSCodeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeExtension : VSCodeObject + { + internal VSCodeExtension(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public VSCodeUri extensionUri + { + get { return Get("extensionUri"); } + } + + public string extensionPath + { + get { return Get("extensionPath"); } + } + + public bool isActive + { + get { return Get("isActive"); } + } + + public object packageJSON + { + get { return Get("packageJSON"); } + } + + public VSCodeExtensionKind extensionKind + { + get { return Get("extensionKind"); } + } + + public object exports + { + get { return Get("exports"); } + } + + public object activate(params object[] arguments) + { + return Invoke("activate", arguments); + } + } + + public sealed class VSCodeExtensionContext : VSCodeObject + { + internal VSCodeExtensionContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] subscriptions + { + get { return Get("subscriptions"); } + } + + public VSCodeMemento workspaceState + { + get { return Get("workspaceState"); } + } + + public VSCodeMemento globalState + { + get { return Get("globalState"); } + } + + public VSCodeUri extensionUri + { + get { return Get("extensionUri"); } + } + + public string extensionPath + { + get { return Get("extensionPath"); } + } + + public VSCodeEnvironmentVariableCollection environmentVariableCollection + { + get { return Get("environmentVariableCollection"); } + } + + public string asAbsolutePath(params object[] arguments) + { + return Invoke("asAbsolutePath", arguments); + } + + public string storagePath + { + get { return Get("storagePath"); } + } + + public string globalStoragePath + { + get { return Get("globalStoragePath"); } + } + + public string logPath + { + get { return Get("logPath"); } + } + } + + public sealed class VSCodeExtensionTerminalOptions : VSCodeObject + { + internal VSCodeExtensionTerminalOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public VSCodePseudoterminal pty + { + get { return Get("pty"); } + } + } + + public sealed class VSCodeFileChangeEvent : VSCodeObject + { + internal VSCodeFileChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFileChangeType type + { + get { return Get("type"); } + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + } + + public sealed class VSCodeFileCreateEvent : VSCodeObject + { + internal VSCodeFileCreateEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri[] files + { + get { return Get("files"); } + } + } + + public sealed class VSCodeFileDeleteEvent : VSCodeObject + { + internal VSCodeFileDeleteEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri[] files + { + get { return Get("files"); } + } + } + + public sealed class VSCodeFileRenameEvent : VSCodeObject + { + internal VSCodeFileRenameEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] files + { + get { return Get("files"); } + } + } + + public sealed class VSCodeFileStat : VSCodeObject + { + internal VSCodeFileStat(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFileType type + { + get { return Get("type"); } + } + + public double ctime + { + get { return Get("ctime"); } + } + + public double mtime + { + get { return Get("mtime"); } + } + + public double size + { + get { return Get("size"); } + } + } + + public sealed class VSCodeFileSystem : VSCodeObject + { + internal VSCodeFileSystem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFileStat stat(params object[] arguments) + { + return Invoke("stat", arguments); + } + + public object[] readDirectory(params object[] arguments) + { + return Invoke("readDirectory", arguments); + } + + public void createDirectory(params object[] arguments) + { + Invoke("createDirectory", arguments); + } + + public object readFile(params object[] arguments) + { + return Invoke("readFile", arguments); + } + + public void writeFile(params object[] arguments) + { + Invoke("writeFile", arguments); + } + + public void delete(params object[] arguments) + { + Invoke("delete", arguments); + } + + public void rename(params object[] arguments) + { + Invoke("rename", arguments); + } + + public void copy(params object[] arguments) + { + Invoke("copy", arguments); + } + } + + public sealed class VSCodeFileSystemProvider : VSCodeObject + { + internal VSCodeFileSystemProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidChangeFile + { + get { return Get("onDidChangeFile"); } + } + + public VSCodeDisposable watch(params object[] arguments) + { + return Invoke("watch", arguments); + } + + public object stat(params object[] arguments) + { + return Invoke("stat", arguments); + } + + public object readDirectory(params object[] arguments) + { + return Invoke("readDirectory", arguments); + } + + public object createDirectory(params object[] arguments) + { + return Invoke("createDirectory", arguments); + } + + public object readFile(params object[] arguments) + { + return Invoke("readFile", arguments); + } + + public object writeFile(params object[] arguments) + { + return Invoke("writeFile", arguments); + } + + public object delete(params object[] arguments) + { + return Invoke("delete", arguments); + } + + public object rename(params object[] arguments) + { + return Invoke("rename", arguments); + } + + public object copy(params object[] arguments) + { + return Invoke("copy", arguments); + } + } + + public sealed class VSCodeFileSystemWatcher : VSCodeObject + { + internal VSCodeFileSystemWatcher(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool ignoreCreateEvents + { + get { return Get("ignoreCreateEvents"); } + } + + public bool ignoreChangeEvents + { + get { return Get("ignoreChangeEvents"); } + } + + public bool ignoreDeleteEvents + { + get { return Get("ignoreDeleteEvents"); } + } + + public VSCodeEvent onDidCreate + { + get { return Get("onDidCreate"); } + } + + public VSCodeEvent onDidChange + { + get { return Get("onDidChange"); } + } + + public VSCodeEvent onDidDelete + { + get { return Get("onDidDelete"); } + } + } + + public sealed class VSCodeFileWillCreateEvent : VSCodeObject + { + internal VSCodeFileWillCreateEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri[] files + { + get { return Get("files"); } + } + + public void waitUntil(params object[] arguments) + { + Invoke("waitUntil", arguments); + } + } + + public sealed class VSCodeFileWillDeleteEvent : VSCodeObject + { + internal VSCodeFileWillDeleteEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri[] files + { + get { return Get("files"); } + } + + public void waitUntil(params object[] arguments) + { + Invoke("waitUntil", arguments); + } + } + + public sealed class VSCodeFileWillRenameEvent : VSCodeObject + { + internal VSCodeFileWillRenameEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] files + { + get { return Get("files"); } + } + + public void waitUntil(params object[] arguments) + { + Invoke("waitUntil", arguments); + } + } + + public sealed class VSCodeFoldingContext : VSCodeObject + { + internal VSCodeFoldingContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeFoldingRangeProvider : VSCodeObject + { + internal VSCodeFoldingRangeProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFoldingRange[] provideFoldingRanges(params object[] arguments) + { + return Invoke("provideFoldingRanges", arguments); + } + } + + public sealed class VSCodeFormattingOptions : VSCodeObject + { + internal VSCodeFormattingOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double tabSize + { + get { return Get("tabSize"); } + } + + public bool insertSpaces + { + get { return Get("insertSpaces"); } + } + } + + public sealed class VSCodeHoverProvider : VSCodeObject + { + internal VSCodeHoverProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeHover provideHover(params object[] arguments) + { + return Invoke("provideHover", arguments); + } + } + + public sealed class VSCodeImplementationProvider : VSCodeObject + { + internal VSCodeImplementationProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object provideImplementation(params object[] arguments) + { + return Invoke("provideImplementation", arguments); + } + } + + public sealed class VSCodeIndentationRule : VSCodeObject + { + internal VSCodeIndentationRule(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object decreaseIndentPattern + { + get { return Get("decreaseIndentPattern"); } + } + + public object increaseIndentPattern + { + get { return Get("increaseIndentPattern"); } + } + + public object indentNextLinePattern + { + get { return Get("indentNextLinePattern"); } + } + + public object unIndentedLinePattern + { + get { return Get("unIndentedLinePattern"); } + } + } + + public sealed class VSCodeInputBox : VSCodeObject + { + internal VSCodeInputBox(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public string placeholder + { + get { return Get("placeholder"); } + } + + public bool password + { + get { return Get("password"); } + } + + public VSCodeEvent onDidChangeValue + { + get { return Get("onDidChangeValue"); } + } + + public VSCodeEvent onDidAccept + { + get { return Get("onDidAccept"); } + } + + public VSCodeQuickInputButton[] buttons + { + get { return Get("buttons"); } + } + + public VSCodeEvent onDidTriggerButton + { + get { return Get("onDidTriggerButton"); } + } + + public string prompt + { + get { return Get("prompt"); } + } + + public string validationMessage + { + get { return Get("validationMessage"); } + } + } + + public sealed class VSCodeInputBoxOptions : VSCodeObject + { + internal VSCodeInputBoxOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public object valueSelection + { + get { return Get("valueSelection"); } + } + + public string prompt + { + get { return Get("prompt"); } + } + + public string placeHolder + { + get { return Get("placeHolder"); } + } + + public bool password + { + get { return Get("password"); } + } + + public bool ignoreFocusOut + { + get { return Get("ignoreFocusOut"); } + } + + public object validateInput(params object[] arguments) + { + return Invoke("validateInput", arguments); + } + } + + public sealed class VSCodeLanguageConfiguration : VSCodeObject + { + internal VSCodeLanguageConfiguration(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCommentRule comments + { + get { return Get("comments"); } + } + + public object[] brackets + { + get { return Get("brackets"); } + } + + public object wordPattern + { + get { return Get("wordPattern"); } + } + + public VSCodeIndentationRule indentationRules + { + get { return Get("indentationRules"); } + } + + public VSCodeOnEnterRule[] onEnterRules + { + get { return Get("onEnterRules"); } + } + + public object __electricCharacterSupport + { + get { return Get("__electricCharacterSupport"); } + } + + public object __characterPairSupport + { + get { return Get("__characterPairSupport"); } + } + } + + public sealed class VSCodeLocationLink : VSCodeObject + { + internal VSCodeLocationLink(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange originSelectionRange + { + get { return Get("originSelectionRange"); } + } + + public VSCodeUri targetUri + { + get { return Get("targetUri"); } + } + + public VSCodeRange targetRange + { + get { return Get("targetRange"); } + } + + public VSCodeRange targetSelectionRange + { + get { return Get("targetSelectionRange"); } + } + } + + public sealed class VSCodeMemento : VSCodeObject + { + internal VSCodeMemento(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object get(params object[] arguments) + { + return Invoke("get", arguments); + } + + public void update(params object[] arguments) + { + Invoke("update", arguments); + } + } + + public sealed class VSCodeMessageItem : VSCodeObject + { + internal VSCodeMessageItem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string title + { + get { return Get("title"); } + } + + public bool isCloseAffordance + { + get { return Get("isCloseAffordance"); } + } + } + + public sealed class VSCodeMessageOptions : VSCodeObject + { + internal VSCodeMessageOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool modal + { + get { return Get("modal"); } + } + } + + public sealed class VSCodeOnEnterRule : VSCodeObject + { + internal VSCodeOnEnterRule(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object beforeText + { + get { return Get("beforeText"); } + } + + public object afterText + { + get { return Get("afterText"); } + } + + public VSCodeEnterAction action + { + get { return Get("action"); } + } + } + + public sealed class VSCodeOnTypeFormattingEditProvider : VSCodeObject + { + internal VSCodeOnTypeFormattingEditProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEdit[] provideOnTypeFormattingEdits(params object[] arguments) + { + return Invoke("provideOnTypeFormattingEdits", arguments); + } + } + + public sealed class VSCodeOpenDialogOptions : VSCodeObject + { + internal VSCodeOpenDialogOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri defaultUri + { + get { return Get("defaultUri"); } + } + + public string openLabel + { + get { return Get("openLabel"); } + } + + public bool canSelectFiles + { + get { return Get("canSelectFiles"); } + } + + public bool canSelectFolders + { + get { return Get("canSelectFolders"); } + } + + public bool canSelectMany + { + get { return Get("canSelectMany"); } + } + + public object filters + { + get { return Get("filters"); } + } + } + + public sealed class VSCodeOutputChannel : VSCodeObject + { + internal VSCodeOutputChannel(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public void append(params object[] arguments) + { + Invoke("append", arguments); + } + + public void appendLine(params object[] arguments) + { + Invoke("appendLine", arguments); + } + + public void clear(params object[] arguments) + { + Invoke("clear", arguments); + } + + public void show(params object[] arguments) + { + Invoke("show", arguments); + } + + public void hide(params object[] arguments) + { + Invoke("hide", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeProcessExecutionOptions : VSCodeObject + { + internal VSCodeProcessExecutionOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string cwd + { + get { return Get("cwd"); } + } + + public object env + { + get { return Get("env"); } + } + } + + public sealed class VSCodeProgress : VSCodeObject + { + internal VSCodeProgress(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void report(params object[] arguments) + { + Invoke("report", arguments); + } + } + + public sealed class VSCodeProgressOptions : VSCodeObject + { + internal VSCodeProgressOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object location + { + get { return Get("location"); } + } + + public string title + { + get { return Get("title"); } + } + + public bool cancellable + { + get { return Get("cancellable"); } + } + } + + public sealed class VSCodePseudoterminal : VSCodeObject + { + internal VSCodePseudoterminal(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidWrite + { + get { return Get("onDidWrite"); } + } + + public VSCodeEvent onDidOverrideDimensions + { + get { return Get("onDidOverrideDimensions"); } + } + + public VSCodeEvent onDidClose + { + get { return Get("onDidClose"); } + } + + public void open(params object[] arguments) + { + Invoke("open", arguments); + } + + public void close(params object[] arguments) + { + Invoke("close", arguments); + } + + public void handleInput(params object[] arguments) + { + Invoke("handleInput", arguments); + } + + public void setDimensions(params object[] arguments) + { + Invoke("setDimensions", arguments); + } + } + + public sealed class VSCodeQuickDiffProvider : VSCodeObject + { + internal VSCodeQuickDiffProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri provideOriginalResource(params object[] arguments) + { + return Invoke("provideOriginalResource", arguments); + } + } + + public sealed class VSCodeQuickInput : VSCodeObject + { + internal VSCodeQuickInput(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string title + { + get { return Get("title"); } + } + + public double step + { + get { return Get("step"); } + } + + public double totalSteps + { + get { return Get("totalSteps"); } + } + + public bool enabled + { + get { return Get("enabled"); } + } + + public bool busy + { + get { return Get("busy"); } + } + + public bool ignoreFocusOut + { + get { return Get("ignoreFocusOut"); } + } + + public void show(params object[] arguments) + { + Invoke("show", arguments); + } + + public void hide(params object[] arguments) + { + Invoke("hide", arguments); + } + + public VSCodeEvent onDidHide + { + get { return Get("onDidHide"); } + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeQuickInputButton : VSCodeObject + { + internal VSCodeQuickInputButton(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object iconPath + { + get { return Get("iconPath"); } + } + + public string tooltip + { + get { return Get("tooltip"); } + } + } + + public sealed class VSCodeQuickPick : VSCodeObject + { + internal VSCodeQuickPick(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public string placeholder + { + get { return Get("placeholder"); } + } + + public VSCodeEvent onDidChangeValue + { + get { return Get("onDidChangeValue"); } + } + + public VSCodeEvent onDidAccept + { + get { return Get("onDidAccept"); } + } + + public VSCodeQuickInputButton[] buttons + { + get { return Get("buttons"); } + } + + public VSCodeEvent onDidTriggerButton + { + get { return Get("onDidTriggerButton"); } + } + + public object[] items + { + get { return Get("items"); } + } + + public bool canSelectMany + { + get { return Get("canSelectMany"); } + } + + public bool matchOnDescription + { + get { return Get("matchOnDescription"); } + } + + public bool matchOnDetail + { + get { return Get("matchOnDetail"); } + } + + public object[] activeItems + { + get { return Get("activeItems"); } + } + + public VSCodeEvent onDidChangeActive + { + get { return Get("onDidChangeActive"); } + } + + public object[] selectedItems + { + get { return Get("selectedItems"); } + } + + public VSCodeEvent onDidChangeSelection + { + get { return Get("onDidChangeSelection"); } + } + } + + public sealed class VSCodeQuickPickItem : VSCodeObject + { + internal VSCodeQuickPickItem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + + public string description + { + get { return Get("description"); } + } + + public string detail + { + get { return Get("detail"); } + } + + public bool picked + { + get { return Get("picked"); } + } + + public bool alwaysShow + { + get { return Get("alwaysShow"); } + } + } + + public sealed class VSCodeQuickPickOptions : VSCodeObject + { + internal VSCodeQuickPickOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool matchOnDescription + { + get { return Get("matchOnDescription"); } + } + + public bool matchOnDetail + { + get { return Get("matchOnDetail"); } + } + + public string placeHolder + { + get { return Get("placeHolder"); } + } + + public bool ignoreFocusOut + { + get { return Get("ignoreFocusOut"); } + } + + public bool canPickMany + { + get { return Get("canPickMany"); } + } + + public object onDidSelectItem(params object[] arguments) + { + return Invoke("onDidSelectItem", arguments); + } + } + + public sealed class VSCodeReferenceContext : VSCodeObject + { + internal VSCodeReferenceContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool includeDeclaration + { + get { return Get("includeDeclaration"); } + } + } + + public sealed class VSCodeReferenceProvider : VSCodeObject + { + internal VSCodeReferenceProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeLocation[] provideReferences(params object[] arguments) + { + return Invoke("provideReferences", arguments); + } + } + + public sealed class VSCodeRenameProvider : VSCodeObject + { + internal VSCodeRenameProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeWorkspaceEdit provideRenameEdits(params object[] arguments) + { + return Invoke("provideRenameEdits", arguments); + } + + public object prepareRename(params object[] arguments) + { + return Invoke("prepareRename", arguments); + } + } + + public sealed class VSCodeRunOptions : VSCodeObject + { + internal VSCodeRunOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool reevaluateOnRerun + { + get { return Get("reevaluateOnRerun"); } + } + } + + public sealed class VSCodeSaveDialogOptions : VSCodeObject + { + internal VSCodeSaveDialogOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri defaultUri + { + get { return Get("defaultUri"); } + } + + public string saveLabel + { + get { return Get("saveLabel"); } + } + + public object filters + { + get { return Get("filters"); } + } + } + + public sealed class VSCodeSelectionRangeProvider : VSCodeObject + { + internal VSCodeSelectionRangeProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSelectionRange[] provideSelectionRanges(params object[] arguments) + { + return Invoke("provideSelectionRanges", arguments); + } + } + + public sealed class VSCodeShellExecutionOptions : VSCodeObject + { + internal VSCodeShellExecutionOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string executable + { + get { return Get("executable"); } + } + + public string[] shellArgs + { + get { return Get("shellArgs"); } + } + + public VSCodeShellQuotingOptions shellQuoting + { + get { return Get("shellQuoting"); } + } + + public string cwd + { + get { return Get("cwd"); } + } + + public object env + { + get { return Get("env"); } + } + } + + public sealed class VSCodeShellQuotedString : VSCodeObject + { + internal VSCodeShellQuotedString(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public VSCodeShellQuoting quoting + { + get { return Get("quoting"); } + } + } + + public sealed class VSCodeShellQuotingOptions : VSCodeObject + { + internal VSCodeShellQuotingOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object escape + { + get { return Get("escape"); } + } + + public string strong + { + get { return Get("strong"); } + } + + public string weak + { + get { return Get("weak"); } + } + } + + public sealed class VSCodeSignatureHelpContext : VSCodeObject + { + internal VSCodeSignatureHelpContext(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSignatureHelpTriggerKind triggerKind + { + get { return Get("triggerKind"); } + } + + public string triggerCharacter + { + get { return Get("triggerCharacter"); } + } + + public bool isRetrigger + { + get { return Get("isRetrigger"); } + } + + public VSCodeSignatureHelp activeSignatureHelp + { + get { return Get("activeSignatureHelp"); } + } + } + + public sealed class VSCodeSignatureHelpProvider : VSCodeObject + { + internal VSCodeSignatureHelpProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSignatureHelp provideSignatureHelp(params object[] arguments) + { + return Invoke("provideSignatureHelp", arguments); + } + } + + public sealed class VSCodeSignatureHelpProviderMetadata : VSCodeObject + { + internal VSCodeSignatureHelpProviderMetadata(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string[] triggerCharacters + { + get { return Get("triggerCharacters"); } + } + + public string[] retriggerCharacters + { + get { return Get("retriggerCharacters"); } + } + } + + public sealed class VSCodeSourceControl : VSCodeObject + { + internal VSCodeSourceControl(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public string label + { + get { return Get("label"); } + } + + public VSCodeUri rootUri + { + get { return Get("rootUri"); } + } + + public VSCodeSourceControlInputBox inputBox + { + get { return Get("inputBox"); } + } + + public double count + { + get { return Get("count"); } + } + + public VSCodeQuickDiffProvider quickDiffProvider + { + get { return Get("quickDiffProvider"); } + } + + public string commitTemplate + { + get { return Get("commitTemplate"); } + } + + public VSCodeCommand acceptInputCommand + { + get { return Get("acceptInputCommand"); } + } + + public VSCodeCommand[] statusBarCommands + { + get { return Get("statusBarCommands"); } + } + + public VSCodeSourceControlResourceGroup createResourceGroup(params object[] arguments) + { + return Invoke("createResourceGroup", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeSourceControlInputBox : VSCodeObject + { + internal VSCodeSourceControlInputBox(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public string placeholder + { + get { return Get("placeholder"); } + } + + public bool visible + { + get { return Get("visible"); } + } + } + + public sealed class VSCodeSourceControlResourceDecorations : VSCodeObject + { + internal VSCodeSourceControlResourceDecorations(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool strikeThrough + { + get { return Get("strikeThrough"); } + } + + public bool faded + { + get { return Get("faded"); } + } + + public string tooltip + { + get { return Get("tooltip"); } + } + + public VSCodeSourceControlResourceThemableDecorations light + { + get { return Get("light"); } + } + + public VSCodeSourceControlResourceThemableDecorations dark + { + get { return Get("dark"); } + } + } + + public sealed class VSCodeSourceControlResourceGroup : VSCodeObject + { + internal VSCodeSourceControlResourceGroup(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public string label + { + get { return Get("label"); } + } + + public bool hideWhenEmpty + { + get { return Get("hideWhenEmpty"); } + } + + public VSCodeSourceControlResourceState[] resourceStates + { + get { return Get("resourceStates"); } + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeSourceControlResourceState : VSCodeObject + { + internal VSCodeSourceControlResourceState(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri resourceUri + { + get { return Get("resourceUri"); } + } + + public VSCodeCommand command + { + get { return Get("command"); } + } + + public VSCodeSourceControlResourceDecorations decorations + { + get { return Get("decorations"); } + } + } + + public sealed class VSCodeSourceControlResourceThemableDecorations : VSCodeObject + { + internal VSCodeSourceControlResourceThemableDecorations(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object iconPath + { + get { return Get("iconPath"); } + } + } + + public sealed class VSCodeStatusBarItem : VSCodeObject + { + internal VSCodeStatusBarItem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeStatusBarAlignment alignment + { + get { return Get("alignment"); } + } + + public double priority + { + get { return Get("priority"); } + } + + public string text + { + get { return Get("text"); } + } + + public string tooltip + { + get { return Get("tooltip"); } + } + + public object color + { + get { return Get("color"); } + } + + public object command + { + get { return Get("command"); } + } + + public void show(params object[] arguments) + { + Invoke("show", arguments); + } + + public void hide(params object[] arguments) + { + Invoke("hide", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeTaskDefinition : VSCodeObject + { + internal VSCodeTaskDefinition(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string type + { + get { return Get("type"); } + } + } + + public sealed class VSCodeTaskEndEvent : VSCodeObject + { + internal VSCodeTaskEndEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskExecution execution + { + get { return Get("execution"); } + } + } + + public sealed class VSCodeTaskExecution : VSCodeObject + { + internal VSCodeTaskExecution(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTask task + { + get { return Get("task"); } + } + + public void terminate(params object[] arguments) + { + Invoke("terminate", arguments); + } + } + + public sealed class VSCodeTaskFilter : VSCodeObject + { + internal VSCodeTaskFilter(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string version + { + get { return Get("version"); } + } + + public string type + { + get { return Get("type"); } + } + } + + public sealed class VSCodeTaskPresentationOptions : VSCodeObject + { + internal VSCodeTaskPresentationOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskRevealKind reveal + { + get { return Get("reveal"); } + } + + public bool echo + { + get { return Get("echo"); } + } + + public bool focus + { + get { return Get("focus"); } + } + + public VSCodeTaskPanelKind panel + { + get { return Get("panel"); } + } + + public bool showReuseMessage + { + get { return Get("showReuseMessage"); } + } + + public bool clear + { + get { return Get("clear"); } + } + } + + public sealed class VSCodeTaskProcessEndEvent : VSCodeObject + { + internal VSCodeTaskProcessEndEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskExecution execution + { + get { return Get("execution"); } + } + + public double exitCode + { + get { return Get("exitCode"); } + } + } + + public sealed class VSCodeTaskProcessStartEvent : VSCodeObject + { + internal VSCodeTaskProcessStartEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskExecution execution + { + get { return Get("execution"); } + } + + public double processId + { + get { return Get("processId"); } + } + } + + public sealed class VSCodeTaskProvider : VSCodeObject + { + internal VSCodeTaskProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] provideTasks(params object[] arguments) + { + return Invoke("provideTasks", arguments); + } + + public object resolveTask(params object[] arguments) + { + return Invoke("resolveTask", arguments); + } + } + + public sealed class VSCodeTaskStartEvent : VSCodeObject + { + internal VSCodeTaskStartEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskExecution execution + { + get { return Get("execution"); } + } + } + + public sealed class VSCodeTerminal : VSCodeObject + { + internal VSCodeTerminal(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public double processId + { + get { return Get("processId"); } + } + + public object creationOptions + { + get { return Get("creationOptions"); } + } + + public VSCodeTerminalExitStatus exitStatus + { + get { return Get("exitStatus"); } + } + + public void sendText(params object[] arguments) + { + Invoke("sendText", arguments); + } + + public void show(params object[] arguments) + { + Invoke("show", arguments); + } + + public void hide(params object[] arguments) + { + Invoke("hide", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeTerminalDimensions : VSCodeObject + { + internal VSCodeTerminalDimensions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double columns + { + get { return Get("columns"); } + } + + public double rows + { + get { return Get("rows"); } + } + } + + public sealed class VSCodeTerminalExitStatus : VSCodeObject + { + internal VSCodeTerminalExitStatus(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double code + { + get { return Get("code"); } + } + } + + public sealed class VSCodeTerminalOptions : VSCodeObject + { + internal VSCodeTerminalOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public string shellPath + { + get { return Get("shellPath"); } + } + + public object shellArgs + { + get { return Get("shellArgs"); } + } + + public object cwd + { + get { return Get("cwd"); } + } + + public object env + { + get { return Get("env"); } + } + + public bool strictEnv + { + get { return Get("strictEnv"); } + } + + public bool hideFromUser + { + get { return Get("hideFromUser"); } + } + } + + public sealed class VSCodeTextDocument : VSCodeObject + { + internal VSCodeTextDocument(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + + public string fileName + { + get { return Get("fileName"); } + } + + public bool isUntitled + { + get { return Get("isUntitled"); } + } + + public string languageId + { + get { return Get("languageId"); } + } + + public double version + { + get { return Get("version"); } + } + + public bool isDirty + { + get { return Get("isDirty"); } + } + + public bool isClosed + { + get { return Get("isClosed"); } + } + + public bool save(params object[] arguments) + { + return Invoke("save", arguments); + } + + public VSCodeEndOfLine eol + { + get { return Get("eol"); } + } + + public double lineCount + { + get { return Get("lineCount"); } + } + + public VSCodeTextLine lineAt(params object[] arguments) + { + return Invoke("lineAt", arguments); + } + + public double offsetAt(params object[] arguments) + { + return Invoke("offsetAt", arguments); + } + + public VSCodePosition positionAt(params object[] arguments) + { + return Invoke("positionAt", arguments); + } + + public string getText(params object[] arguments) + { + return Invoke("getText", arguments); + } + + public VSCodeRange getWordRangeAtPosition(params object[] arguments) + { + return Invoke("getWordRangeAtPosition", arguments); + } + + public VSCodeRange validateRange(params object[] arguments) + { + return Invoke("validateRange", arguments); + } + + public VSCodePosition validatePosition(params object[] arguments) + { + return Invoke("validatePosition", arguments); + } + } + + public sealed class VSCodeTextDocumentChangeEvent : VSCodeObject + { + internal VSCodeTextDocumentChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextDocument document + { + get { return Get("document"); } + } + + public VSCodeTextDocumentContentChangeEvent[] contentChanges + { + get { return Get("contentChanges"); } + } + } + + public sealed class VSCodeTextDocumentContentChangeEvent : VSCodeObject + { + internal VSCodeTextDocumentContentChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public double rangeOffset + { + get { return Get("rangeOffset"); } + } + + public double rangeLength + { + get { return Get("rangeLength"); } + } + + public string text + { + get { return Get("text"); } + } + } + + public sealed class VSCodeTextDocumentContentProvider : VSCodeObject + { + internal VSCodeTextDocumentContentProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidChange + { + get { return Get("onDidChange"); } + } + + public string provideTextDocumentContent(params object[] arguments) + { + return Invoke("provideTextDocumentContent", arguments); + } + } + + public sealed class VSCodeTextDocumentShowOptions : VSCodeObject + { + internal VSCodeTextDocumentShowOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeViewColumn viewColumn + { + get { return Get("viewColumn"); } + } + + public bool preserveFocus + { + get { return Get("preserveFocus"); } + } + + public bool preview + { + get { return Get("preview"); } + } + + public VSCodeRange selection + { + get { return Get("selection"); } + } + } + + public sealed class VSCodeTextDocumentWillSaveEvent : VSCodeObject + { + internal VSCodeTextDocumentWillSaveEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextDocument document + { + get { return Get("document"); } + } + + public VSCodeTextDocumentSaveReason reason + { + get { return Get("reason"); } + } + + public void waitUntil(params object[] arguments) + { + Invoke("waitUntil", arguments); + } + } + + public sealed class VSCodeTextEditor : VSCodeObject + { + internal VSCodeTextEditor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextDocument document + { + get { return Get("document"); } + } + + public VSCodeSelection selection + { + get { return Get("selection"); } + } + + public VSCodeSelection[] selections + { + get { return Get("selections"); } + } + + public VSCodeRange[] visibleRanges + { + get { return Get("visibleRanges"); } + } + + public VSCodeTextEditorOptions options + { + get { return Get("options"); } + } + + public VSCodeViewColumn viewColumn + { + get { return Get("viewColumn"); } + } + + public bool edit(params object[] arguments) + { + return Invoke("edit", arguments); + } + + public bool insertSnippet(params object[] arguments) + { + return Invoke("insertSnippet", arguments); + } + + public void setDecorations(params object[] arguments) + { + Invoke("setDecorations", arguments); + } + + public void revealRange(params object[] arguments) + { + Invoke("revealRange", arguments); + } + + public void show(params object[] arguments) + { + Invoke("show", arguments); + } + + public void hide(params object[] arguments) + { + Invoke("hide", arguments); + } + } + + public sealed class VSCodeTextEditorDecorationType : VSCodeObject + { + internal VSCodeTextEditorDecorationType(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string key + { + get { return Get("key"); } + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeTextEditorEdit : VSCodeObject + { + internal VSCodeTextEditorEdit(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void replace(params object[] arguments) + { + Invoke("replace", arguments); + } + + public void insert(params object[] arguments) + { + Invoke("insert", arguments); + } + + public void delete(params object[] arguments) + { + Invoke("delete", arguments); + } + + public void setEndOfLine(params object[] arguments) + { + Invoke("setEndOfLine", arguments); + } + } + + public sealed class VSCodeTextEditorOptions : VSCodeObject + { + internal VSCodeTextEditorOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object tabSize + { + get { return Get("tabSize"); } + } + + public object insertSpaces + { + get { return Get("insertSpaces"); } + } + + public VSCodeTextEditorCursorStyle cursorStyle + { + get { return Get("cursorStyle"); } + } + + public VSCodeTextEditorLineNumbersStyle lineNumbers + { + get { return Get("lineNumbers"); } + } + } + + public sealed class VSCodeTextEditorOptionsChangeEvent : VSCodeObject + { + internal VSCodeTextEditorOptionsChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEditor textEditor + { + get { return Get("textEditor"); } + } + + public VSCodeTextEditorOptions options + { + get { return Get("options"); } + } + } + + public sealed class VSCodeTextEditorSelectionChangeEvent : VSCodeObject + { + internal VSCodeTextEditorSelectionChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEditor textEditor + { + get { return Get("textEditor"); } + } + + public VSCodeSelection[] selections + { + get { return Get("selections"); } + } + + public VSCodeTextEditorSelectionChangeKind kind + { + get { return Get("kind"); } + } + } + + public sealed class VSCodeTextEditorViewColumnChangeEvent : VSCodeObject + { + internal VSCodeTextEditorViewColumnChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEditor textEditor + { + get { return Get("textEditor"); } + } + + public VSCodeViewColumn viewColumn + { + get { return Get("viewColumn"); } + } + } + + public sealed class VSCodeTextEditorVisibleRangesChangeEvent : VSCodeObject + { + internal VSCodeTextEditorVisibleRangesChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEditor textEditor + { + get { return Get("textEditor"); } + } + + public VSCodeRange[] visibleRanges + { + get { return Get("visibleRanges"); } + } + } + + public sealed class VSCodeTextLine : VSCodeObject + { + internal VSCodeTextLine(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double lineNumber + { + get { return Get("lineNumber"); } + } + + public string text + { + get { return Get("text"); } + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeRange rangeIncludingLineBreak + { + get { return Get("rangeIncludingLineBreak"); } + } + + public double firstNonWhitespaceCharacterIndex + { + get { return Get("firstNonWhitespaceCharacterIndex"); } + } + + public bool isEmptyOrWhitespace + { + get { return Get("isEmptyOrWhitespace"); } + } + } + + public sealed class VSCodeThemableDecorationAttachmentRenderOptions : VSCodeObject + { + internal VSCodeThemableDecorationAttachmentRenderOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string contentText + { + get { return Get("contentText"); } + } + + public object contentIconPath + { + get { return Get("contentIconPath"); } + } + + public string border + { + get { return Get("border"); } + } + + public object borderColor + { + get { return Get("borderColor"); } + } + + public string fontStyle + { + get { return Get("fontStyle"); } + } + + public string fontWeight + { + get { return Get("fontWeight"); } + } + + public string textDecoration + { + get { return Get("textDecoration"); } + } + + public object color + { + get { return Get("color"); } + } + + public object backgroundColor + { + get { return Get("backgroundColor"); } + } + + public string margin + { + get { return Get("margin"); } + } + + public string width + { + get { return Get("width"); } + } + + public string height + { + get { return Get("height"); } + } + } + + public sealed class VSCodeThemableDecorationInstanceRenderOptions : VSCodeObject + { + internal VSCodeThemableDecorationInstanceRenderOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeThemableDecorationAttachmentRenderOptions before + { + get { return Get("before"); } + } + + public VSCodeThemableDecorationAttachmentRenderOptions after + { + get { return Get("after"); } + } + } + + public sealed class VSCodeThemableDecorationRenderOptions : VSCodeObject + { + internal VSCodeThemableDecorationRenderOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object backgroundColor + { + get { return Get("backgroundColor"); } + } + + public string outline + { + get { return Get("outline"); } + } + + public object outlineColor + { + get { return Get("outlineColor"); } + } + + public string outlineStyle + { + get { return Get("outlineStyle"); } + } + + public string outlineWidth + { + get { return Get("outlineWidth"); } + } + + public string border + { + get { return Get("border"); } + } + + public object borderColor + { + get { return Get("borderColor"); } + } + + public string borderRadius + { + get { return Get("borderRadius"); } + } + + public string borderSpacing + { + get { return Get("borderSpacing"); } + } + + public string borderStyle + { + get { return Get("borderStyle"); } + } + + public string borderWidth + { + get { return Get("borderWidth"); } + } + + public string fontStyle + { + get { return Get("fontStyle"); } + } + + public string fontWeight + { + get { return Get("fontWeight"); } + } + + public string textDecoration + { + get { return Get("textDecoration"); } + } + + public string cursor + { + get { return Get("cursor"); } + } + + public object color + { + get { return Get("color"); } + } + + public string opacity + { + get { return Get("opacity"); } + } + + public string letterSpacing + { + get { return Get("letterSpacing"); } + } + + public object gutterIconPath + { + get { return Get("gutterIconPath"); } + } + + public string gutterIconSize + { + get { return Get("gutterIconSize"); } + } + + public object overviewRulerColor + { + get { return Get("overviewRulerColor"); } + } + + public VSCodeThemableDecorationAttachmentRenderOptions before + { + get { return Get("before"); } + } + + public VSCodeThemableDecorationAttachmentRenderOptions after + { + get { return Get("after"); } + } + } + + public sealed class VSCodeTreeDataProvider : VSCodeObject + { + internal VSCodeTreeDataProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidChangeTreeData + { + get { return Get("onDidChangeTreeData"); } + } + + public object getTreeItem(params object[] arguments) + { + return Invoke("getTreeItem", arguments); + } + + public object[] getChildren(params object[] arguments) + { + return Invoke("getChildren", arguments); + } + + public object getParent(params object[] arguments) + { + return Invoke("getParent", arguments); + } + } + + public sealed class VSCodeTreeView : VSCodeObject + { + internal VSCodeTreeView(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent onDidExpandElement + { + get { return Get("onDidExpandElement"); } + } + + public VSCodeEvent onDidCollapseElement + { + get { return Get("onDidCollapseElement"); } + } + + public object[] selection + { + get { return Get("selection"); } + } + + public VSCodeEvent onDidChangeSelection + { + get { return Get("onDidChangeSelection"); } + } + + public bool visible + { + get { return Get("visible"); } + } + + public VSCodeEvent onDidChangeVisibility + { + get { return Get("onDidChangeVisibility"); } + } + + public string message + { + get { return Get("message"); } + } + + public string title + { + get { return Get("title"); } + } + + public void reveal(params object[] arguments) + { + Invoke("reveal", arguments); + } + } + + public sealed class VSCodeTreeViewExpansionEvent : VSCodeObject + { + internal VSCodeTreeViewExpansionEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object element + { + get { return Get("element"); } + } + } + + public sealed class VSCodeTreeViewOptions : VSCodeObject + { + internal VSCodeTreeViewOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTreeDataProvider treeDataProvider + { + get { return Get("treeDataProvider"); } + } + + public bool showCollapseAll + { + get { return Get("showCollapseAll"); } + } + + public bool canSelectMany + { + get { return Get("canSelectMany"); } + } + } + + public sealed class VSCodeTreeViewSelectionChangeEvent : VSCodeObject + { + internal VSCodeTreeViewSelectionChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] selection + { + get { return Get("selection"); } + } + } + + public sealed class VSCodeTreeViewVisibilityChangeEvent : VSCodeObject + { + internal VSCodeTreeViewVisibilityChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool visible + { + get { return Get("visible"); } + } + } + + public sealed class VSCodeTypeDefinitionProvider : VSCodeObject + { + internal VSCodeTypeDefinitionProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object provideTypeDefinition(params object[] arguments) + { + return Invoke("provideTypeDefinition", arguments); + } + } + + public sealed class VSCodeUriHandler : VSCodeObject + { + internal VSCodeUriHandler(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void handleUri(params object[] arguments) + { + Invoke("handleUri", arguments); + } + } + + public sealed class VSCodeWebview : VSCodeObject + { + internal VSCodeWebview(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeWebviewOptions options + { + get { return Get("options"); } + } + + public string html + { + get { return Get("html"); } + } + + public VSCodeEvent onDidReceiveMessage + { + get { return Get("onDidReceiveMessage"); } + } + + public bool postMessage(params object[] arguments) + { + return Invoke("postMessage", arguments); + } + + public VSCodeUri asWebviewUri(params object[] arguments) + { + return Invoke("asWebviewUri", arguments); + } + + public string cspSource + { + get { return Get("cspSource"); } + } + } + + public sealed class VSCodeWebviewOptions : VSCodeObject + { + internal VSCodeWebviewOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool enableScripts + { + get { return Get("enableScripts"); } + } + + public bool enableCommandUris + { + get { return Get("enableCommandUris"); } + } + + public VSCodeUri[] localResourceRoots + { + get { return Get("localResourceRoots"); } + } + + public VSCodeWebviewPortMapping[] portMapping + { + get { return Get("portMapping"); } + } + } + + public sealed class VSCodeWebviewPanel : VSCodeObject + { + internal VSCodeWebviewPanel(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string viewType + { + get { return Get("viewType"); } + } + + public string title + { + get { return Get("title"); } + } + + public object iconPath + { + get { return Get("iconPath"); } + } + + public VSCodeWebview webview + { + get { return Get("webview"); } + } + + public VSCodeWebviewPanelOptions options + { + get { return Get("options"); } + } + + public VSCodeViewColumn viewColumn + { + get { return Get("viewColumn"); } + } + + public bool active + { + get { return Get("active"); } + } + + public bool visible + { + get { return Get("visible"); } + } + + public VSCodeEvent onDidChangeViewState + { + get { return Get("onDidChangeViewState"); } + } + + public VSCodeEvent onDidDispose + { + get { return Get("onDidDispose"); } + } + + public void reveal(params object[] arguments) + { + Invoke("reveal", arguments); + } + + public object dispose(params object[] arguments) + { + return Invoke("dispose", arguments); + } + } + + public sealed class VSCodeWebviewPanelOnDidChangeViewStateEvent : VSCodeObject + { + internal VSCodeWebviewPanelOnDidChangeViewStateEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeWebviewPanel webviewPanel + { + get { return Get("webviewPanel"); } + } + } + + public sealed class VSCodeWebviewPanelOptions : VSCodeObject + { + internal VSCodeWebviewPanelOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool enableFindWidget + { + get { return Get("enableFindWidget"); } + } + + public bool retainContextWhenHidden + { + get { return Get("retainContextWhenHidden"); } + } + } + + public sealed class VSCodeWebviewPanelSerializer : VSCodeObject + { + internal VSCodeWebviewPanelSerializer(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void deserializeWebviewPanel(params object[] arguments) + { + Invoke("deserializeWebviewPanel", arguments); + } + } + + public sealed class VSCodeWebviewPortMapping : VSCodeObject + { + internal VSCodeWebviewPortMapping(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double webviewPort + { + get { return Get("webviewPort"); } + } + + public double extensionHostPort + { + get { return Get("extensionHostPort"); } + } + } + + public sealed class VSCodeWindowState : VSCodeObject + { + internal VSCodeWindowState(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool focused + { + get { return Get("focused"); } + } + } + + public sealed class VSCodeWorkspaceConfiguration : VSCodeObject + { + internal VSCodeWorkspaceConfiguration(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object get(params object[] arguments) + { + return Invoke("get", arguments); + } + + public bool has(params object[] arguments) + { + return Invoke("has", arguments); + } + + public object inspect(params object[] arguments) + { + return Invoke("inspect", arguments); + } + + public void update(params object[] arguments) + { + Invoke("update", arguments); + } + } + + public sealed class VSCodeWorkspaceEditEntryMetadata : VSCodeObject + { + internal VSCodeWorkspaceEditEntryMetadata(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool needsConfirmation + { + get { return Get("needsConfirmation"); } + } + + public string label + { + get { return Get("label"); } + } + + public string description + { + get { return Get("description"); } + } + + public object iconPath + { + get { return Get("iconPath"); } + } + } + + public sealed class VSCodeWorkspaceFolder : VSCodeObject + { + internal VSCodeWorkspaceFolder(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + + public string name + { + get { return Get("name"); } + } + + public double index + { + get { return Get("index"); } + } + } + + public sealed class VSCodeWorkspaceFolderPickOptions : VSCodeObject + { + internal VSCodeWorkspaceFolderPickOptions(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string placeHolder + { + get { return Get("placeHolder"); } + } + + public bool ignoreFocusOut + { + get { return Get("ignoreFocusOut"); } + } + } + + public sealed class VSCodeWorkspaceFoldersChangeEvent : VSCodeObject + { + internal VSCodeWorkspaceFoldersChangeEvent(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeWorkspaceFolder[] added + { + get { return Get("added"); } + } + + public VSCodeWorkspaceFolder[] removed + { + get { return Get("removed"); } + } + } + + public sealed class VSCodeWorkspaceSymbolProvider : VSCodeObject + { + internal VSCodeWorkspaceSymbolProvider(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] provideWorkspaceSymbols(params object[] arguments) + { + return Invoke("provideWorkspaceSymbols", arguments); + } + + public object resolveWorkspaceSymbol(params object[] arguments) + { + return Invoke("resolveWorkspaceSymbol", arguments); + } + } + + public sealed class VSCodeBreakpoint : VSCodeObject + { + internal VSCodeBreakpoint(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string id + { + get { return Get("id"); } + } + + public bool enabled + { + get { return Get("enabled"); } + } + + public string condition + { + get { return Get("condition"); } + } + + public string hitCondition + { + get { return Get("hitCondition"); } + } + + public string logMessage + { + get { return Get("logMessage"); } + } + } + + public sealed class VSCodeBreakpointConstructor : VSCodeObject + { + internal VSCodeBreakpointConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeBreakpoint @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCallHierarchyIncomingCall : VSCodeObject + { + internal VSCodeCallHierarchyIncomingCall(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCallHierarchyItem from + { + get { return Get("from"); } + } + + public VSCodeRange[] fromRanges + { + get { return Get("fromRanges"); } + } + } + + public sealed class VSCodeCallHierarchyIncomingCallConstructor : VSCodeObject + { + internal VSCodeCallHierarchyIncomingCallConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCallHierarchyIncomingCall @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCallHierarchyItem : VSCodeObject + { + internal VSCodeCallHierarchyItem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public VSCodeSymbolKind kind + { + get { return Get("kind"); } + } + + public VSCodeSymbolTag[] tags + { + get { return Get("tags"); } + } + + public string detail + { + get { return Get("detail"); } + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeRange selectionRange + { + get { return Get("selectionRange"); } + } + } + + public sealed class VSCodeCallHierarchyItemConstructor : VSCodeObject + { + internal VSCodeCallHierarchyItemConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCallHierarchyItem @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCallHierarchyOutgoingCall : VSCodeObject + { + internal VSCodeCallHierarchyOutgoingCall(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCallHierarchyItem to + { + get { return Get("to"); } + } + + public VSCodeRange[] fromRanges + { + get { return Get("fromRanges"); } + } + } + + public sealed class VSCodeCallHierarchyOutgoingCallConstructor : VSCodeObject + { + internal VSCodeCallHierarchyOutgoingCallConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCallHierarchyOutgoingCall @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCancellationTokenSource : VSCodeObject + { + internal VSCodeCancellationTokenSource(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCancellationToken token + { + get { return Get("token"); } + } + + public void cancel(params object[] arguments) + { + Invoke("cancel", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeCancellationTokenSourceConstructor : VSCodeObject + { + internal VSCodeCancellationTokenSourceConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCancellationTokenSource @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCodeAction : VSCodeObject + { + internal VSCodeCodeAction(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string title + { + get { return Get("title"); } + } + + public VSCodeWorkspaceEdit edit + { + get { return Get("edit"); } + } + + public VSCodeDiagnostic[] diagnostics + { + get { return Get("diagnostics"); } + } + + public VSCodeCommand command + { + get { return Get("command"); } + } + + public VSCodeCodeActionKind kind + { + get { return Get("kind"); } + } + + public bool isPreferred + { + get { return Get("isPreferred"); } + } + + public object disabled + { + get { return Get("disabled"); } + } + } + + public sealed class VSCodeCodeActionConstructor : VSCodeObject + { + internal VSCodeCodeActionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCodeAction @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCodeActionKind : VSCodeObject + { + internal VSCodeCodeActionKind(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public VSCodeCodeActionKind append(params object[] arguments) + { + return Invoke("append", arguments); + } + + public bool intersects(params object[] arguments) + { + return Invoke("intersects", arguments); + } + + public bool contains(params object[] arguments) + { + return Invoke("contains", arguments); + } + } + + public sealed class VSCodeCodeActionKindConstructor : VSCodeObject + { + internal VSCodeCodeActionKindConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCodeActionKind @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeCodeActionKind Empty + { + get { return Get("Empty"); } + } + + public VSCodeCodeActionKind QuickFix + { + get { return Get("QuickFix"); } + } + + public VSCodeCodeActionKind Refactor + { + get { return Get("Refactor"); } + } + + public VSCodeCodeActionKind RefactorExtract + { + get { return Get("RefactorExtract"); } + } + + public VSCodeCodeActionKind RefactorInline + { + get { return Get("RefactorInline"); } + } + + public VSCodeCodeActionKind RefactorRewrite + { + get { return Get("RefactorRewrite"); } + } + + public VSCodeCodeActionKind Source + { + get { return Get("Source"); } + } + + public VSCodeCodeActionKind SourceOrganizeImports + { + get { return Get("SourceOrganizeImports"); } + } + + public VSCodeCodeActionKind SourceFixAll + { + get { return Get("SourceFixAll"); } + } + } + + public sealed class VSCodeCodeLens : VSCodeObject + { + internal VSCodeCodeLens(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeCommand command + { + get { return Get("command"); } + } + + public bool isResolved + { + get { return Get("isResolved"); } + } + } + + public sealed class VSCodeCodeLensConstructor : VSCodeObject + { + internal VSCodeCodeLensConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCodeLens @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeColor : VSCodeObject + { + internal VSCodeColor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double red + { + get { return Get("red"); } + } + + public double green + { + get { return Get("green"); } + } + + public double blue + { + get { return Get("blue"); } + } + + public double alpha + { + get { return Get("alpha"); } + } + } + + public sealed class VSCodeColorConstructor : VSCodeObject + { + internal VSCodeColorConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeColor @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeColorInformation : VSCodeObject + { + internal VSCodeColorInformation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeColor color + { + get { return Get("color"); } + } + } + + public sealed class VSCodeColorInformationConstructor : VSCodeObject + { + internal VSCodeColorInformationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeColorInformation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeColorPresentation : VSCodeObject + { + internal VSCodeColorPresentation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + + public VSCodeTextEdit textEdit + { + get { return Get("textEdit"); } + } + + public VSCodeTextEdit[] additionalTextEdits + { + get { return Get("additionalTextEdits"); } + } + } + + public sealed class VSCodeColorPresentationConstructor : VSCodeObject + { + internal VSCodeColorPresentationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeColorPresentation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCompletionItem : VSCodeObject + { + internal VSCodeCompletionItem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + + public VSCodeCompletionItemKind kind + { + get { return Get("kind"); } + } + + public VSCodeCompletionItemTag[] tags + { + get { return Get("tags"); } + } + + public string detail + { + get { return Get("detail"); } + } + + public object documentation + { + get { return Get("documentation"); } + } + + public string sortText + { + get { return Get("sortText"); } + } + + public string filterText + { + get { return Get("filterText"); } + } + + public bool preselect + { + get { return Get("preselect"); } + } + + public object insertText + { + get { return Get("insertText"); } + } + + public object range + { + get { return Get("range"); } + } + + public string[] commitCharacters + { + get { return Get("commitCharacters"); } + } + + public bool keepWhitespace + { + get { return Get("keepWhitespace"); } + } + + public VSCodeTextEdit textEdit + { + get { return Get("textEdit"); } + } + + public VSCodeTextEdit[] additionalTextEdits + { + get { return Get("additionalTextEdits"); } + } + + public VSCodeCommand command + { + get { return Get("command"); } + } + } + + public sealed class VSCodeCompletionItemConstructor : VSCodeObject + { + internal VSCodeCompletionItemConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCompletionItem @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCompletionList : VSCodeObject + { + internal VSCodeCompletionList(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public bool isIncomplete + { + get { return Get("isIncomplete"); } + } + + public object[] items + { + get { return Get("items"); } + } + } + + public sealed class VSCodeCompletionListConstructor : VSCodeObject + { + internal VSCodeCompletionListConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCompletionList @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeCustomExecution : VSCodeObject + { + internal VSCodeCustomExecution(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeCustomExecutionConstructor : VSCodeObject + { + internal VSCodeCustomExecutionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeCustomExecution @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDebugAdapterExecutable : VSCodeObject + { + internal VSCodeDebugAdapterExecutable(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string command + { + get { return Get("command"); } + } + + public string[] args + { + get { return Get("args"); } + } + + public VSCodeDebugAdapterExecutableOptions options + { + get { return Get("options"); } + } + } + + public sealed class VSCodeDebugAdapterExecutableConstructor : VSCodeObject + { + internal VSCodeDebugAdapterExecutableConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugAdapterExecutable @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDebugAdapterInlineImplementation : VSCodeObject + { + internal VSCodeDebugAdapterInlineImplementation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeDebugAdapterInlineImplementationConstructor : VSCodeObject + { + internal VSCodeDebugAdapterInlineImplementationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugAdapterInlineImplementation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDebugAdapterServer : VSCodeObject + { + internal VSCodeDebugAdapterServer(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double port + { + get { return Get("port"); } + } + + public string host + { + get { return Get("host"); } + } + } + + public sealed class VSCodeDebugAdapterServerConstructor : VSCodeObject + { + internal VSCodeDebugAdapterServerConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDebugAdapterServer @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDiagnostic : VSCodeObject + { + internal VSCodeDiagnostic(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public string message + { + get { return Get("message"); } + } + + public VSCodeDiagnosticSeverity severity + { + get { return Get("severity"); } + } + + public string source + { + get { return Get("source"); } + } + + public object code + { + get { return Get("code"); } + } + + public VSCodeDiagnosticRelatedInformation[] relatedInformation + { + get { return Get("relatedInformation"); } + } + + public VSCodeDiagnosticTag[] tags + { + get { return Get("tags"); } + } + } + + public sealed class VSCodeDiagnosticConstructor : VSCodeObject + { + internal VSCodeDiagnosticConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDiagnostic @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDiagnosticRelatedInformation : VSCodeObject + { + internal VSCodeDiagnosticRelatedInformation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeLocation location + { + get { return Get("location"); } + } + + public string message + { + get { return Get("message"); } + } + } + + public sealed class VSCodeDiagnosticRelatedInformationConstructor : VSCodeObject + { + internal VSCodeDiagnosticRelatedInformationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDiagnosticRelatedInformation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDisposable : VSCodeObject + { + internal VSCodeDisposable(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object dispose(params object[] arguments) + { + return Invoke("dispose", arguments); + } + } + + public sealed class VSCodeDisposableConstructor : VSCodeObject + { + internal VSCodeDisposableConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDisposable @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeDisposable from(params object[] arguments) + { + return Invoke("from", arguments); + } + } + + public sealed class VSCodeDocumentHighlight : VSCodeObject + { + internal VSCodeDocumentHighlight(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeDocumentHighlightKind kind + { + get { return Get("kind"); } + } + } + + public sealed class VSCodeDocumentHighlightConstructor : VSCodeObject + { + internal VSCodeDocumentHighlightConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDocumentHighlight @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDocumentLink : VSCodeObject + { + internal VSCodeDocumentLink(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeUri target + { + get { return Get("target"); } + } + + public string tooltip + { + get { return Get("tooltip"); } + } + } + + public sealed class VSCodeDocumentLinkConstructor : VSCodeObject + { + internal VSCodeDocumentLinkConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDocumentLink @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeDocumentSymbol : VSCodeObject + { + internal VSCodeDocumentSymbol(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public string detail + { + get { return Get("detail"); } + } + + public VSCodeSymbolKind kind + { + get { return Get("kind"); } + } + + public VSCodeSymbolTag[] tags + { + get { return Get("tags"); } + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeRange selectionRange + { + get { return Get("selectionRange"); } + } + + public VSCodeDocumentSymbol[] children + { + get { return Get("children"); } + } + } + + public sealed class VSCodeDocumentSymbolConstructor : VSCodeObject + { + internal VSCodeDocumentSymbolConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeDocumentSymbol @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeEvaluatableExpression : VSCodeObject + { + internal VSCodeEvaluatableExpression(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public string expression + { + get { return Get("expression"); } + } + } + + public sealed class VSCodeEvaluatableExpressionConstructor : VSCodeObject + { + internal VSCodeEvaluatableExpressionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvaluatableExpression @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeEventEmitter : VSCodeObject + { + internal VSCodeEventEmitter(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEvent @event + { + get { return Get("event"); } + } + + public void fire(params object[] arguments) + { + Invoke("fire", arguments); + } + + public void dispose(params object[] arguments) + { + Invoke("dispose", arguments); + } + } + + public sealed class VSCodeEventEmitterConstructor : VSCodeObject + { + internal VSCodeEventEmitterConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeEventEmitter @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeFileSystemError : VSCodeObject + { + internal VSCodeFileSystemError(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string code + { + get { return Get("code"); } + } + } + + public sealed class VSCodeFileSystemErrorConstructor : VSCodeObject + { + internal VSCodeFileSystemErrorConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFileSystemError @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeFileSystemError FileNotFound(params object[] arguments) + { + return Invoke("FileNotFound", arguments); + } + + public VSCodeFileSystemError FileExists(params object[] arguments) + { + return Invoke("FileExists", arguments); + } + + public VSCodeFileSystemError FileNotADirectory(params object[] arguments) + { + return Invoke("FileNotADirectory", arguments); + } + + public VSCodeFileSystemError FileIsADirectory(params object[] arguments) + { + return Invoke("FileIsADirectory", arguments); + } + + public VSCodeFileSystemError NoPermissions(params object[] arguments) + { + return Invoke("NoPermissions", arguments); + } + + public VSCodeFileSystemError Unavailable(params object[] arguments) + { + return Invoke("Unavailable", arguments); + } + } + + public sealed class VSCodeFoldingRange : VSCodeObject + { + internal VSCodeFoldingRange(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double start + { + get { return Get("start"); } + } + + public double end + { + get { return Get("end"); } + } + + public VSCodeFoldingRangeKind kind + { + get { return Get("kind"); } + } + } + + public sealed class VSCodeFoldingRangeConstructor : VSCodeObject + { + internal VSCodeFoldingRangeConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFoldingRange @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeFunctionBreakpoint : VSCodeObject + { + internal VSCodeFunctionBreakpoint(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string functionName + { + get { return Get("functionName"); } + } + } + + public sealed class VSCodeFunctionBreakpointConstructor : VSCodeObject + { + internal VSCodeFunctionBreakpointConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeFunctionBreakpoint @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeHover : VSCodeObject + { + internal VSCodeHover(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object[] contents + { + get { return Get("contents"); } + } + + public VSCodeRange range + { + get { return Get("range"); } + } + } + + public sealed class VSCodeHoverConstructor : VSCodeObject + { + internal VSCodeHoverConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeHover @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeLocation : VSCodeObject + { + internal VSCodeLocation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri uri + { + get { return Get("uri"); } + } + + public VSCodeRange range + { + get { return Get("range"); } + } + } + + public sealed class VSCodeLocationConstructor : VSCodeObject + { + internal VSCodeLocationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeLocation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeMarkdownString : VSCodeObject + { + internal VSCodeMarkdownString(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public bool isTrusted + { + get { return Get("isTrusted"); } + } + + public VSCodeMarkdownString appendText(params object[] arguments) + { + return Invoke("appendText", arguments); + } + + public VSCodeMarkdownString appendMarkdown(params object[] arguments) + { + return Invoke("appendMarkdown", arguments); + } + + public VSCodeMarkdownString appendCodeblock(params object[] arguments) + { + return Invoke("appendCodeblock", arguments); + } + } + + public sealed class VSCodeMarkdownStringConstructor : VSCodeObject + { + internal VSCodeMarkdownStringConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeMarkdownString @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeParameterInformation : VSCodeObject + { + internal VSCodeParameterInformation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object label + { + get { return Get("label"); } + } + + public object documentation + { + get { return Get("documentation"); } + } + } + + public sealed class VSCodeParameterInformationConstructor : VSCodeObject + { + internal VSCodeParameterInformationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeParameterInformation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodePosition : VSCodeObject + { + internal VSCodePosition(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double line + { + get { return Get("line"); } + } + + public double character + { + get { return Get("character"); } + } + + public bool isBefore(params object[] arguments) + { + return Invoke("isBefore", arguments); + } + + public bool isBeforeOrEqual(params object[] arguments) + { + return Invoke("isBeforeOrEqual", arguments); + } + + public bool isAfter(params object[] arguments) + { + return Invoke("isAfter", arguments); + } + + public bool isAfterOrEqual(params object[] arguments) + { + return Invoke("isAfterOrEqual", arguments); + } + + public bool isEqual(params object[] arguments) + { + return Invoke("isEqual", arguments); + } + + public double compareTo(params object[] arguments) + { + return Invoke("compareTo", arguments); + } + + public VSCodePosition translate(params object[] arguments) + { + return Invoke("translate", arguments); + } + + public VSCodePosition with(params object[] arguments) + { + return Invoke("with", arguments); + } + } + + public sealed class VSCodePositionConstructor : VSCodeObject + { + internal VSCodePositionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodePosition @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeProcessExecution : VSCodeObject + { + internal VSCodeProcessExecution(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string process + { + get { return Get("process"); } + } + + public string[] args + { + get { return Get("args"); } + } + + public VSCodeProcessExecutionOptions options + { + get { return Get("options"); } + } + } + + public sealed class VSCodeProcessExecutionConstructor : VSCodeObject + { + internal VSCodeProcessExecutionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeProcessExecution @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeQuickInputButtons : VSCodeObject + { + internal VSCodeQuickInputButtons(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeQuickInputButtonsConstructor : VSCodeObject + { + internal VSCodeQuickInputButtonsConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeQuickInputButtons @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeQuickInputButton Back + { + get { return Get("Back"); } + } + } + + public sealed class VSCodeRange : VSCodeObject + { + internal VSCodeRange(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodePosition start + { + get { return Get("start"); } + } + + public VSCodePosition end + { + get { return Get("end"); } + } + + public bool isEmpty + { + get { return Get("isEmpty"); } + } + + public bool isSingleLine + { + get { return Get("isSingleLine"); } + } + + public bool contains(params object[] arguments) + { + return Invoke("contains", arguments); + } + + public bool isEqual(params object[] arguments) + { + return Invoke("isEqual", arguments); + } + + public VSCodeRange intersection(params object[] arguments) + { + return Invoke("intersection", arguments); + } + + public VSCodeRange union(params object[] arguments) + { + return Invoke("union", arguments); + } + + public VSCodeRange with(params object[] arguments) + { + return Invoke("with", arguments); + } + } + + public sealed class VSCodeRangeConstructor : VSCodeObject + { + internal VSCodeRangeConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeRelativePattern : VSCodeObject + { + internal VSCodeRelativePattern(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string @base + { + get { return Get("base"); } + } + + public string pattern + { + get { return Get("pattern"); } + } + } + + public sealed class VSCodeRelativePatternConstructor : VSCodeObject + { + internal VSCodeRelativePatternConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRelativePattern @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSelection : VSCodeObject + { + internal VSCodeSelection(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodePosition anchor + { + get { return Get("anchor"); } + } + + public VSCodePosition active + { + get { return Get("active"); } + } + + public bool isReversed + { + get { return Get("isReversed"); } + } + } + + public sealed class VSCodeSelectionConstructor : VSCodeObject + { + internal VSCodeSelectionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSelection @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSelectionRange : VSCodeObject + { + internal VSCodeSelectionRange(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public VSCodeSelectionRange parent + { + get { return Get("parent"); } + } + } + + public sealed class VSCodeSelectionRangeConstructor : VSCodeObject + { + internal VSCodeSelectionRangeConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSelectionRange @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSemanticTokens : VSCodeObject + { + internal VSCodeSemanticTokens(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string resultId + { + get { return Get("resultId"); } + } + + public object data + { + get { return Get("data"); } + } + } + + public sealed class VSCodeSemanticTokensConstructor : VSCodeObject + { + internal VSCodeSemanticTokensConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSemanticTokens @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSemanticTokensBuilder : VSCodeObject + { + internal VSCodeSemanticTokensBuilder(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public void push(params object[] arguments) + { + Invoke("push", arguments); + } + + public VSCodeSemanticTokens build(params object[] arguments) + { + return Invoke("build", arguments); + } + } + + public sealed class VSCodeSemanticTokensBuilderConstructor : VSCodeObject + { + internal VSCodeSemanticTokensBuilderConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSemanticTokensBuilder @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSemanticTokensEdit : VSCodeObject + { + internal VSCodeSemanticTokensEdit(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double start + { + get { return Get("start"); } + } + + public double deleteCount + { + get { return Get("deleteCount"); } + } + + public object data + { + get { return Get("data"); } + } + } + + public sealed class VSCodeSemanticTokensEditConstructor : VSCodeObject + { + internal VSCodeSemanticTokensEditConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSemanticTokensEdit @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSemanticTokensEdits : VSCodeObject + { + internal VSCodeSemanticTokensEdits(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string resultId + { + get { return Get("resultId"); } + } + + public VSCodeSemanticTokensEdit[] edits + { + get { return Get("edits"); } + } + } + + public sealed class VSCodeSemanticTokensEditsConstructor : VSCodeObject + { + internal VSCodeSemanticTokensEditsConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSemanticTokensEdits @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSemanticTokensLegend : VSCodeObject + { + internal VSCodeSemanticTokensLegend(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string[] tokenTypes + { + get { return Get("tokenTypes"); } + } + + public string[] tokenModifiers + { + get { return Get("tokenModifiers"); } + } + } + + public sealed class VSCodeSemanticTokensLegendConstructor : VSCodeObject + { + internal VSCodeSemanticTokensLegendConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSemanticTokensLegend @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeShellExecution : VSCodeObject + { + internal VSCodeShellExecution(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string commandLine + { + get { return Get("commandLine"); } + } + + public object command + { + get { return Get("command"); } + } + + public object[] args + { + get { return Get("args"); } + } + + public VSCodeShellExecutionOptions options + { + get { return Get("options"); } + } + } + + public sealed class VSCodeShellExecutionConstructor : VSCodeObject + { + internal VSCodeShellExecutionConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeShellExecution @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSignatureHelp : VSCodeObject + { + internal VSCodeSignatureHelp(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSignatureInformation[] signatures + { + get { return Get("signatures"); } + } + + public double activeSignature + { + get { return Get("activeSignature"); } + } + + public double activeParameter + { + get { return Get("activeParameter"); } + } + } + + public sealed class VSCodeSignatureHelpConstructor : VSCodeObject + { + internal VSCodeSignatureHelpConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSignatureHelp @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSignatureInformation : VSCodeObject + { + internal VSCodeSignatureInformation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + + public object documentation + { + get { return Get("documentation"); } + } + + public VSCodeParameterInformation[] parameters + { + get { return Get("parameters"); } + } + + public double activeParameter + { + get { return Get("activeParameter"); } + } + } + + public sealed class VSCodeSignatureInformationConstructor : VSCodeObject + { + internal VSCodeSignatureInformationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSignatureInformation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSnippetString : VSCodeObject + { + internal VSCodeSnippetString(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string value + { + get { return Get("value"); } + } + + public VSCodeSnippetString appendText(params object[] arguments) + { + return Invoke("appendText", arguments); + } + + public VSCodeSnippetString appendTabstop(params object[] arguments) + { + return Invoke("appendTabstop", arguments); + } + + public VSCodeSnippetString appendPlaceholder(params object[] arguments) + { + return Invoke("appendPlaceholder", arguments); + } + + public VSCodeSnippetString appendChoice(params object[] arguments) + { + return Invoke("appendChoice", arguments); + } + + public VSCodeSnippetString appendVariable(params object[] arguments) + { + return Invoke("appendVariable", arguments); + } + } + + public sealed class VSCodeSnippetStringConstructor : VSCodeObject + { + internal VSCodeSnippetStringConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSnippetString @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSourceBreakpoint : VSCodeObject + { + internal VSCodeSourceBreakpoint(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeLocation location + { + get { return Get("location"); } + } + } + + public sealed class VSCodeSourceBreakpointConstructor : VSCodeObject + { + internal VSCodeSourceBreakpointConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSourceBreakpoint @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeSymbolInformation : VSCodeObject + { + internal VSCodeSymbolInformation(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string name + { + get { return Get("name"); } + } + + public string containerName + { + get { return Get("containerName"); } + } + + public VSCodeSymbolKind kind + { + get { return Get("kind"); } + } + + public VSCodeSymbolTag[] tags + { + get { return Get("tags"); } + } + + public VSCodeLocation location + { + get { return Get("location"); } + } + } + + public sealed class VSCodeSymbolInformationConstructor : VSCodeObject + { + internal VSCodeSymbolInformationConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeSymbolInformation @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeTask : VSCodeObject + { + internal VSCodeTask(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskDefinition definition + { + get { return Get("definition"); } + } + + public object scope + { + get { return Get("scope"); } + } + + public string name + { + get { return Get("name"); } + } + + public object execution + { + get { return Get("execution"); } + } + + public bool isBackground + { + get { return Get("isBackground"); } + } + + public string source + { + get { return Get("source"); } + } + + public VSCodeTaskGroup group + { + get { return Get("group"); } + } + + public VSCodeTaskPresentationOptions presentationOptions + { + get { return Get("presentationOptions"); } + } + + public string[] problemMatchers + { + get { return Get("problemMatchers"); } + } + + public VSCodeRunOptions runOptions + { + get { return Get("runOptions"); } + } + } + + public sealed class VSCodeTaskConstructor : VSCodeObject + { + internal VSCodeTaskConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTask @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeTaskGroup : VSCodeObject + { + internal VSCodeTaskGroup(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeTaskGroupConstructor : VSCodeObject + { + internal VSCodeTaskGroupConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTaskGroup @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeTaskGroup Clean + { + get { return Get("Clean"); } + } + + public VSCodeTaskGroup Build + { + get { return Get("Build"); } + } + + public VSCodeTaskGroup Rebuild + { + get { return Get("Rebuild"); } + } + + public VSCodeTaskGroup Test + { + get { return Get("Test"); } + } + } + + public sealed class VSCodeTextEdit : VSCodeObject + { + internal VSCodeTextEdit(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeRange range + { + get { return Get("range"); } + } + + public string newText + { + get { return Get("newText"); } + } + + public VSCodeEndOfLine newEol + { + get { return Get("newEol"); } + } + } + + public sealed class VSCodeTextEditConstructor : VSCodeObject + { + internal VSCodeTextEditConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTextEdit @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeTextEdit replace(params object[] arguments) + { + return Invoke("replace", arguments); + } + + public VSCodeTextEdit insert(params object[] arguments) + { + return Invoke("insert", arguments); + } + + public VSCodeTextEdit delete(params object[] arguments) + { + return Invoke("delete", arguments); + } + + public VSCodeTextEdit setEndOfLine(params object[] arguments) + { + return Invoke("setEndOfLine", arguments); + } + } + + public sealed class VSCodeThemeColor : VSCodeObject + { + internal VSCodeThemeColor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeThemeColorConstructor : VSCodeObject + { + internal VSCodeThemeColorConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeThemeColor @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeThemeIcon : VSCodeObject + { + internal VSCodeThemeIcon(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + } + + public sealed class VSCodeThemeIconConstructor : VSCodeObject + { + internal VSCodeThemeIconConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeThemeIcon @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeThemeIcon File + { + get { return Get("File"); } + } + + public VSCodeThemeIcon Folder + { + get { return Get("Folder"); } + } + } + + public sealed class VSCodeTreeItem : VSCodeObject + { + internal VSCodeTreeItem(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string label + { + get { return Get("label"); } + } + + public string id + { + get { return Get("id"); } + } + + public object iconPath + { + get { return Get("iconPath"); } + } + + public object description + { + get { return Get("description"); } + } + + public VSCodeUri resourceUri + { + get { return Get("resourceUri"); } + } + + public string tooltip + { + get { return Get("tooltip"); } + } + + public VSCodeCommand command + { + get { return Get("command"); } + } + + public VSCodeTreeItemCollapsibleState collapsibleState + { + get { return Get("collapsibleState"); } + } + + public string contextValue + { + get { return Get("contextValue"); } + } + } + + public sealed class VSCodeTreeItemConstructor : VSCodeObject + { + internal VSCodeTreeItemConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeTreeItem @new(params object[] arguments) + { + return Construct(arguments); + } + } + + public sealed class VSCodeUri : VSCodeObject + { + internal VSCodeUri(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public string scheme + { + get { return Get("scheme"); } + } + + public string authority + { + get { return Get("authority"); } + } + + public string path + { + get { return Get("path"); } + } + + public string query + { + get { return Get("query"); } + } + + public string fragment + { + get { return Get("fragment"); } + } + + public string fsPath + { + get { return Get("fsPath"); } + } + + public VSCodeUri with(params object[] arguments) + { + return Invoke("with", arguments); + } + + public string toString(params object[] arguments) + { + return Invoke("toString", arguments); + } + + public object toJSON(params object[] arguments) + { + return Invoke("toJSON", arguments); + } + } + + public sealed class VSCodeUriConstructor : VSCodeObject + { + internal VSCodeUriConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeUri @new(params object[] arguments) + { + return Construct(arguments); + } + + public VSCodeUri parse(params object[] arguments) + { + return Invoke("parse", arguments); + } + + public VSCodeUri file(params object[] arguments) + { + return Invoke("file", arguments); + } + + public VSCodeUri joinPath(params object[] arguments) + { + return Invoke("joinPath", arguments); + } + } + + public sealed class VSCodeWorkspaceEdit : VSCodeObject + { + internal VSCodeWorkspaceEdit(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public double size + { + get { return Get("size"); } + } + + public void replace(params object[] arguments) + { + Invoke("replace", arguments); + } + + public void insert(params object[] arguments) + { + Invoke("insert", arguments); + } + + public void delete(params object[] arguments) + { + Invoke("delete", arguments); + } + + public bool has(params object[] arguments) + { + return Invoke("has", arguments); + } + + public void set(params object[] arguments) + { + Invoke("set", arguments); + } + + public VSCodeTextEdit[] get(params object[] arguments) + { + return Invoke("get", arguments); + } + + public void createFile(params object[] arguments) + { + Invoke("createFile", arguments); + } + + public void deleteFile(params object[] arguments) + { + Invoke("deleteFile", arguments); + } + + public void renameFile(params object[] arguments) + { + Invoke("renameFile", arguments); + } + + public object[] entries(params object[] arguments) + { + return Invoke("entries", arguments); + } + } + + public sealed class VSCodeWorkspaceEditConstructor : VSCodeObject + { + internal VSCodeWorkspaceEditConstructor(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public VSCodeWorkspaceEdit @new(params object[] arguments) + { + return Construct(arguments); + } + } + +} + diff --git a/HostInjection/PowerShellProTools.VSCode.psm1 b/HostInjection/PowerShellProTools.VSCode.psm1 index 304d2a7..1f7303f 100644 --- a/HostInjection/PowerShellProTools.VSCode.psm1 +++ b/HostInjection/PowerShellProTools.VSCode.psm1 @@ -1,2 +1,8 @@ Import-Module "$PSScriptRoot\PowerShellProTools.VSCode.dll" -Import-Module "$PSScriptRoot\PowerShellProTools.SharedCommands.dll" \ No newline at end of file +Import-Module "$PSScriptRoot\PowerShellProTools.SharedCommands.dll" + +if (Get-Variable -Name vscode -Scope Global -ErrorAction SilentlyContinue) { + Remove-Variable -Name vscode -Scope Global -Force +} + +Set-Variable -Name vscode -Scope Global -Option ReadOnly -Value ([PowerShellToolsPro.Cmdlets.VSCode.VSCodeApiBootstrap]::Create()) diff --git a/HostInjection/VSCodeApiProxy.cs b/HostInjection/VSCodeApiProxy.cs new file mode 100644 index 0000000..6dfdd23 --- /dev/null +++ b/HostInjection/VSCodeApiProxy.cs @@ -0,0 +1,482 @@ +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using System; +using System.Diagnostics; +using System.IO; +using System.IO.Pipes; +using System.Linq; +using System.Management.Automation; +using System.Reflection; +using System.Text; + +namespace PowerShellToolsPro.Cmdlets.VSCode +{ + public sealed class VSCodeProxyTarget + { + [JsonProperty("path")] + public string[] Path { get; set; } + + [JsonProperty("handle")] + public int? Handle { get; set; } + + [JsonProperty("typeName")] + public string TypeName { get; set; } + } + + public sealed class VSCodeProxyArgument + { + [JsonProperty("kind")] + public string Kind { get; set; } + + [JsonProperty("value")] + public object Value { get; set; } + + [JsonProperty("handle")] + public int? Handle { get; set; } + + [JsonProperty("path")] + public string[] Path { get; set; } + } + + public sealed class VSCodeProxyRequest + { + [JsonProperty("protocol")] + public string Protocol { get; set; } = "vscode-api"; + + [JsonProperty("id")] + public string Id { get; set; } + + [JsonProperty("operation")] + public string Operation { get; set; } + + [JsonProperty("target")] + public VSCodeProxyTarget Target { get; set; } + + [JsonProperty("member")] + public string Member { get; set; } + + [JsonProperty("arguments")] + public VSCodeProxyArgument[] Arguments { get; set; } + } + + public sealed class VSCodeProxyResponse + { + [JsonProperty("id")] + public string Id { get; set; } + + [JsonProperty("success")] + public bool Success { get; set; } + + [JsonProperty("error")] + public string Error { get; set; } + + [JsonProperty("result")] + public VSCodeProxyResult Result { get; set; } + } + + public sealed class VSCodeProxyResult + { + [JsonProperty("kind")] + public string Kind { get; set; } + + [JsonProperty("value")] + public JToken Value { get; set; } + + [JsonProperty("handle")] + public int? Handle { get; set; } + + [JsonProperty("typeName")] + public string TypeName { get; set; } + + [JsonProperty("items")] + public VSCodeProxyResult[] Items { get; set; } + } + + public class VSCodeObject + { + internal VSCodeObject(VSCodeProxyClient client, VSCodeProxyTarget target) + { + Client = client; + Target = target; + } + + internal VSCodeProxyClient Client { get; } + internal VSCodeProxyTarget Target { get; } + + public string ApiPath + { + get + { + if (Target?.Path == null) + { + return null; + } + + return "vscode." + string.Join(".", Target.Path); + } + } + + public string ApiTypeName => Target?.TypeName ?? GetType().Name; + + public int? ApiHandle => Target?.Handle; + + public object GetApiProperty(string member) + { + return Client.Get(Target, member); + } + + public string GetApiPropertyJson(string member) + { + return Client.GetRaw(Target, member); + } + + public string TestApiProperty(string member) + { + try + { + var value = Client.Get(Target, member); + return value == null ? "" : $"{value} ({value.GetType().FullName})"; + } + catch (Exception ex) + { + return ex.ToString(); + } + } + + public override string ToString() + { + if (ApiPath != null) + { + return ApiPath; + } + + return ApiTypeName ?? base.ToString(); + } + + protected T Get(string member) + { + return Client.Get(Target, member); + } + + protected T Invoke(string member, params object[] arguments) + { + return Client.Invoke(Target, member, arguments); + } + + protected void Invoke(string member, params object[] arguments) + { + Client.Invoke(Target, member, arguments); + } + + protected T Construct(params object[] arguments) + { + return Client.Construct(Target, arguments); + } + } + + public sealed class VSCodeUnknownObject : VSCodeObject + { + internal VSCodeUnknownObject(VSCodeProxyClient client, VSCodeProxyTarget target) + : base(client, target) + { + } + + public object Get(string member) + { + return Client.Get(Target, member); + } + + public new object Invoke(string member, params object[] arguments) + { + return Client.Invoke(Target, member, arguments); + } + } + + public sealed class VSCodeProxyClient + { + private static readonly Lazy DefaultClient = new Lazy(() => new VSCodeProxyClient()); + private static readonly int ProcessId = Process.GetCurrentProcess().Id; + + public static VSCodeProxyClient Default => DefaultClient.Value; + + public T Get(VSCodeProxyTarget target, string member) + { + return Send("get", target, member, Array.Empty()); + } + + public string GetRaw(VSCodeProxyTarget target, string member) + { + var request = new VSCodeProxyRequest + { + Id = Guid.NewGuid().ToString("N"), + Operation = "get", + Target = target, + Member = member, + Arguments = Array.Empty() + }; + + return SendRequest(request); + } + + public T Invoke(VSCodeProxyTarget target, string member, params object[] arguments) + { + return Send("invoke", target, member, arguments); + } + + public T Construct(VSCodeProxyTarget target, params object[] arguments) + { + return Send("construct", target, null, arguments); + } + + internal static VSCodeProxyTarget Path(params string[] path) + { + return new VSCodeProxyTarget { Path = path }; + } + + private T Send(string operation, VSCodeProxyTarget target, string member, object[] arguments) + { + var request = new VSCodeProxyRequest + { + Id = Guid.NewGuid().ToString("N"), + Operation = operation, + Target = target, + Member = member, + Arguments = (arguments ?? Array.Empty()).Select(ConvertArgument).ToArray() + }; + + var responseJson = SendRequest(request); + var response = JsonConvert.DeserializeObject(responseJson); + if (response == null) + { + throw new InvalidOperationException("VS Code API returned an empty response."); + } + + if (!response.Success) + { + throw new InvalidOperationException(response.Error ?? "VS Code API request failed."); + } + + return ConvertResult(response.Result); + } + + private static string SendRequest(VSCodeProxyRequest request) + { + using (var namedPipeClient = new NamedPipeClientStream(".", $"PPTPipeCode{ProcessId}", PipeDirection.InOut)) + { + namedPipeClient.Connect(5000); + + var requestBytes = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(request) + "!PS"); + namedPipeClient.Write(requestBytes, 0, requestBytes.Length); + namedPipeClient.Flush(); + + try + { + namedPipeClient.WaitForPipeDrain(); + } + catch (PlatformNotSupportedException) + { + } + catch (IOException) + { + // The VS Code side may close immediately after reading the request. + } + + return ReadResponse(namedPipeClient); + } + } + + private static string ReadResponse(NamedPipeClientStream namedPipeClient) + { + var buffer = new byte[4096]; + using (var memoryStream = new MemoryStream()) + { + while (true) + { + int read; + try + { + var readTask = namedPipeClient.ReadAsync(buffer, 0, buffer.Length); + if (!readTask.Wait(10000)) + { + throw new TimeoutException("Timed out waiting for a response from the VS Code API bridge."); + } + + read = readTask.Result; + } + catch (IOException) + { + if (memoryStream.Length > 0) + { + break; + } + + throw; + } + catch (ObjectDisposedException) + { + if (memoryStream.Length > 0) + { + break; + } + + throw; + } + + if (read == 0) + { + break; + } + + memoryStream.Write(buffer, 0, read); + } + + return Encoding.UTF8.GetString(memoryStream.ToArray()); + } + } + + private static VSCodeProxyArgument ConvertArgument(object value) + { + if (value == null) + { + return new VSCodeProxyArgument { Kind = "null" }; + } + + if (value is VSCodeObject vscodeObject) + { + return new VSCodeProxyArgument + { + Kind = "target", + Handle = vscodeObject.Target.Handle, + Path = vscodeObject.Target.Path, + Value = vscodeObject.Target.TypeName + }; + } + + if (value is Enum) + { + return new VSCodeProxyArgument { Kind = "primitive", Value = Convert.ToInt32(value) }; + } + + return new VSCodeProxyArgument { Kind = "value", Value = value }; + } + + private T ConvertResult(VSCodeProxyResult result) + { + if (result == null || result.Kind == "null" || result.Kind == "undefined") + { + return default(T); + } + + var targetType = typeof(T); + if (targetType == typeof(void)) + { + return default(T); + } + + if (result.Kind == "array") + { + return ConvertArray(result); + } + + if (result.Kind == "handle") + { + return ConvertHandle(result); + } + + if (targetType == typeof(object)) + { + return (T)ConvertToObject(result); + } + + if (result.Value == null) + { + return default(T); + } + + return result.Value.ToObject(); + } + + private T ConvertArray(VSCodeProxyResult result) + { + var targetType = typeof(T); + if (!targetType.IsArray) + { + if (targetType == typeof(object)) + { + return (T)(object)result.Items.Select(ConvertToObject).ToArray(); + } + + return default(T); + } + + var elementType = targetType.GetElementType(); + var items = result.Items ?? Array.Empty(); + var array = Array.CreateInstance(elementType, items.Length); + var method = typeof(VSCodeProxyClient).GetMethod(nameof(ConvertResult), BindingFlags.Instance | BindingFlags.NonPublic); + var generic = method.MakeGenericMethod(elementType); + + for (var index = 0; index < items.Length; index++) + { + array.SetValue(generic.Invoke(this, new object[] { items[index] }), index); + } + + return (T)(object)array; + } + + private T ConvertHandle(VSCodeProxyResult result) + { + var target = new VSCodeProxyTarget + { + Handle = result.Handle, + TypeName = result.TypeName + }; + + var targetType = typeof(T); + if (targetType == typeof(object) || targetType == typeof(VSCodeUnknownObject)) + { + return (T)(object)new VSCodeUnknownObject(this, target); + } + + if (!typeof(VSCodeObject).IsAssignableFrom(targetType)) + { + return default(T); + } + + return (T)Activator.CreateInstance(targetType, BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.Public, null, new object[] { this, target }, null); + } + + private object ConvertToObject(VSCodeProxyResult result) + { + if (result == null || result.Kind == "null" || result.Kind == "undefined") + { + return null; + } + + if (result.Kind == "array") + { + return (result.Items ?? Array.Empty()).Select(ConvertToObject).ToArray(); + } + + if (result.Kind == "handle") + { + return ConvertHandle(result); + } + + return result.Value?.ToObject(); + } + } + + public static class VSCodeApiBootstrap + { + public static object Create() + { + var apiType = typeof(VSCodeProxyClient).Assembly.GetType("PowerShellToolsPro.Cmdlets.VSCode.VSCodeApi"); + if (apiType == null) + { + throw new InvalidOperationException("The generated VS Code API surface was not found."); + } + + return Activator.CreateInstance(apiType, BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.Public, null, new object[] { VSCodeProxyClient.Default }, null); + } + } +} diff --git a/vscode/powershellprotools/.vscode/tasks.json b/vscode/powershellprotools/.vscode/tasks.json index f695a71..ccc16c2 100644 --- a/vscode/powershellprotools/.vscode/tasks.json +++ b/vscode/powershellprotools/.vscode/tasks.json @@ -6,7 +6,17 @@ { "type": "npm", "script": "watch", - "problemMatcher": "$tsc-watch", + "problemMatcher": { + "owner": "esbuild", + "pattern": { + "regexp": "^(?!)" + }, + "background": { + "activeOnStart": true, + "beginsPattern": "^.*esbuild .*--watch.*$", + "endsPattern": "^\\[watch\\] build finished, watching for changes\\.\\.\\.$" + } + }, "isBackground": true, "presentation": { "reveal": "never" @@ -61,4 +71,4 @@ "problemMatcher": [] } ] -} \ No newline at end of file +} diff --git a/vscode/powershellprotools/package-lock.json b/vscode/powershellprotools/package-lock.json index 231958f..964480d 100644 --- a/vscode/powershellprotools/package-lock.json +++ b/vscode/powershellprotools/package-lock.json @@ -7,9 +7,10 @@ "": { "name": "powershellprotools", "version": "2025.11.0", + "license": "MIT", "dependencies": { "axios": "^0.21.1", - "cheerio": "^1.0.0-rc.2", + "cheerio": "1.0.0-rc.2", "extract-zip": "^2.0.1", "json-rpc2": "^2.0.0", "moment": "^2.28.0", @@ -22,7 +23,7 @@ "devDependencies": { "@types/mocha": "^2.2.42", "@types/node": "^14.11.2", - "@types/vscode": "^1.46.0", + "@types/vscode": "1.46.0", "esbuild": "^0.13.8", "tslint": "^5.8.0", "typescript": "^4.0.2" @@ -67,13 +68,12 @@ "version": "14.18.63", "resolved": "https://registry.npmjs.org/@types/node/-/node-14.18.63.tgz", "integrity": "sha512-fAtCfv4jJg+ExtXhvCkCqUKZ+4ok/JQk01qDKhL5BDDoS3AxKXhV5/MAVUZyQnSEd2GT92fkgZl0pz0Q0AzcIQ==", - "devOptional": true, "license": "MIT" }, "node_modules/@types/vscode": { - "version": "1.106.1", - "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.106.1.tgz", - "integrity": "sha512-R/HV8u2h8CAddSbX8cjpdd7B8/GnE4UjgjpuGuHcbp1xV6yh4OeqU4L1pKjlwujCrSFS0MOpwJAIs/NexMB1fQ==", + "version": "1.46.0", + "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.46.0.tgz", + "integrity": "sha512-8m9wPEB2mcRqTWNKs9A9Eqs8DrQZt0qNFO8GkxBOnyW6xR//3s77SoMgb/nY1ctzACsZXwZj3YRTDsn4bAoaUw==", "dev": true, "license": "MIT" }, @@ -187,45 +187,20 @@ } }, "node_modules/cheerio": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.1.2.tgz", - "integrity": "sha512-IkxPpb5rS/d1IiLbHMgfPuS0FgiWTtFIm/Nj+2woXDLTZ7fOT2eqzgYbdMlLweqlHbsZjxEChoVK+7iph7jyQg==", + "version": "1.0.0-rc.2", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.2.tgz", + "integrity": "sha512-9LDHQy1jHc/eXMzPN6/oah9Qba4CjdKECC7YYEE/2zge/tsGwt19NQp5NFdfd5Lx6TZlyC5SXNQkG41P9r6XDg==", "license": "MIT", "dependencies": { - "cheerio-select": "^2.1.0", - "dom-serializer": "^2.0.0", - "domhandler": "^5.0.3", - "domutils": "^3.2.2", - "encoding-sniffer": "^0.2.1", - "htmlparser2": "^10.0.0", - "parse5": "^7.3.0", - "parse5-htmlparser2-tree-adapter": "^7.1.0", - "parse5-parser-stream": "^7.1.2", - "undici": "^7.12.0", - "whatwg-mimetype": "^4.0.0" + "css-select": "~1.2.0", + "dom-serializer": "~0.1.0", + "entities": "~1.1.1", + "htmlparser2": "^3.9.1", + "lodash": "^4.15.0", + "parse5": "^3.0.1" }, "engines": { - "node": ">=20.18.1" - }, - "funding": { - "url": "https://github.com/cheeriojs/cheerio?sponsor=1" - } - }, - "node_modules/cheerio-select": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-2.1.0.tgz", - "integrity": "sha512-9v9kG0LvzrlcungtnJtpGNxY+fzECQKhK4EGJX2vByejiMX84MFNQw4UxPJl3bFbTMw+Dfs37XaIkCwTZfLh4g==", - "license": "BSD-2-Clause", - "dependencies": { - "boolbase": "^1.0.0", - "css-select": "^5.1.0", - "css-what": "^6.1.0", - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3", - "domutils": "^3.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" + "node": ">= 0.6" } }, "node_modules/color-convert": { @@ -260,31 +235,24 @@ "license": "MIT" }, "node_modules/css-select": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-5.2.2.tgz", - "integrity": "sha512-TizTzUddG/xYLA3NXodFM0fSbNizXjOKhqiQQwvhlspadZokn1KDy0NZFS0wuEubIYAV5/c1/lAr0TaaFXEXzw==", - "license": "BSD-2-Clause", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-1.2.0.tgz", + "integrity": "sha512-dUQOBoqdR7QwV90WysXPLXG5LO7nhYBgiWVfxF80DKPF8zx1t/pUd2FYy73emg3zrjtM6dzmYgbHKfV2rxiHQA==", + "license": "BSD-like", "dependencies": { - "boolbase": "^1.0.0", - "css-what": "^6.1.0", - "domhandler": "^5.0.2", - "domutils": "^3.0.1", - "nth-check": "^2.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" + "boolbase": "~1.0.0", + "css-what": "2.1", + "domutils": "1.5.1", + "nth-check": "~1.0.1" } }, "node_modules/css-what": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.2.2.tgz", - "integrity": "sha512-u/O3vwbptzhMs3L1fQE82ZSLHQQfto5gyZzwteVIEyeaY5Fc7R4dapF/BvRoSYFeqfBk4m0V1Vafq5Pjv25wvA==", + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-2.1.3.tgz", + "integrity": "sha512-a+EPoD+uZiNfh+5fxw2nO9QwFa6nJe2Or35fGY6Ipw1R3R4AGz1d1TEZrCegvw2YTmZ0jXirGYlzxxpYSHwpEg==", "license": "BSD-2-Clause", "engines": { - "node": ">= 6" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" + "node": "*" } }, "node_modules/debug": { @@ -315,71 +283,37 @@ } }, "node_modules/dom-serializer": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-2.0.0.tgz", - "integrity": "sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==", + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.1.tgz", + "integrity": "sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA==", "license": "MIT", "dependencies": { - "domelementtype": "^2.3.0", - "domhandler": "^5.0.2", - "entities": "^4.2.0" - }, - "funding": { - "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + "domelementtype": "^1.3.0", + "entities": "^1.1.1" } }, "node_modules/domelementtype": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", - "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/fb55" - } - ], + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz", + "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==", "license": "BSD-2-Clause" }, "node_modules/domhandler": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-5.0.3.tgz", - "integrity": "sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz", + "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==", "license": "BSD-2-Clause", "dependencies": { - "domelementtype": "^2.3.0" - }, - "engines": { - "node": ">= 4" - }, - "funding": { - "url": "https://github.com/fb55/domhandler?sponsor=1" + "domelementtype": "1" } }, "node_modules/domutils": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.2.2.tgz", - "integrity": "sha512-6kZKyUajlDuqlHKVX1w7gyslj9MPIXzIFiz/rGu35uC1wMi+kMhQwGhl4lt9unC9Vb9INnY9Z3/ZA3+FhASLaw==", - "license": "BSD-2-Clause", - "dependencies": { - "dom-serializer": "^2.0.0", - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3" - }, - "funding": { - "url": "https://github.com/fb55/domutils?sponsor=1" - } - }, - "node_modules/encoding-sniffer": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/encoding-sniffer/-/encoding-sniffer-0.2.1.tgz", - "integrity": "sha512-5gvq20T6vfpekVtqrYQsSCFZ1wEg5+wW0/QaZMWkFr6BqD3NfKs0rLCx4rrVlSWJeZb5NBJgVLswK/w2MWU+Gw==", - "license": "MIT", + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.5.1.tgz", + "integrity": "sha512-gSu5Oi/I+3wDENBsOWBiRK1eoGxcywYSqg3rR960/+EfY0CF4EX1VPkgHOZ3WiS/Jg2DtliF6BhWcHlfpYUcGw==", "dependencies": { - "iconv-lite": "^0.6.3", - "whatwg-encoding": "^3.1.1" - }, - "funding": { - "url": "https://github.com/fb55/encoding-sniffer?sponsor=1" + "dom-serializer": "0", + "domelementtype": "1" } }, "node_modules/end-of-stream": { @@ -392,16 +326,10 @@ } }, "node_modules/entities": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", - "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" - } + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz", + "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==", + "license": "BSD-2-Clause" }, "node_modules/es5class": { "version": "2.3.1", @@ -846,34 +774,17 @@ } }, "node_modules/htmlparser2": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-10.0.0.tgz", - "integrity": "sha512-TwAZM+zE5Tq3lrEHvOlvwgj1XLWQCtaaibSN11Q+gGBAS7Y1uZSWwXXRe4iF6OXnaq1riyQAPFOBtYc77Mxq0g==", - "funding": [ - "https://github.com/fb55/htmlparser2?sponsor=1", - { - "type": "github", - "url": "https://github.com/sponsors/fb55" - } - ], + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", + "integrity": "sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ==", "license": "MIT", "dependencies": { - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3", - "domutils": "^3.2.1", - "entities": "^6.0.0" - } - }, - "node_modules/htmlparser2/node_modules/entities": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", - "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" + "domelementtype": "^1.3.1", + "domhandler": "^2.3.0", + "domutils": "^1.5.1", + "entities": "^1.1.1", + "inherits": "^2.0.1", + "readable-stream": "^3.1.1" } }, "node_modules/http-parser-js": { @@ -882,18 +793,6 @@ "integrity": "sha512-Pysuw9XpUq5dVc/2SMHpuTY01RFl8fttgcyunjL7eEMhGM3cI4eOmiCycJDVCo/7O7ClfQD3SaI6ftDzqOXYMA==", "license": "MIT" }, - "node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", @@ -910,7 +809,6 @@ "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true, "license": "ISC" }, "node_modules/is-core-module": { @@ -1043,15 +941,12 @@ } }, "node_modules/nth-check": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", - "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz", + "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==", "license": "BSD-2-Clause", "dependencies": { - "boolbase": "^1.0.0" - }, - "funding": { - "url": "https://github.com/fb55/nth-check?sponsor=1" + "boolbase": "~1.0.0" } }, "node_modules/object-assign": { @@ -1073,52 +968,12 @@ } }, "node_modules/parse5": { - "version": "7.3.0", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", - "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", - "license": "MIT", - "dependencies": { - "entities": "^6.0.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, - "node_modules/parse5-htmlparser2-tree-adapter": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-7.1.0.tgz", - "integrity": "sha512-ruw5xyKs6lrpo9x9rCZqZZnIUntICjQAd0Wsmp396Ul9lN/h+ifgVV1x1gZHi8euej6wTfpqX8j+BFQxF0NS/g==", - "license": "MIT", - "dependencies": { - "domhandler": "^5.0.3", - "parse5": "^7.0.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, - "node_modules/parse5-parser-stream": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/parse5-parser-stream/-/parse5-parser-stream-7.1.2.tgz", - "integrity": "sha512-JyeQc9iwFLn5TbvvqACIF/VXG6abODeB3Fwmv/TGdLk2LfbWkaySGY72at4+Ty7EkPZj854u4CrICqNk2qIbow==", + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-3.0.3.tgz", + "integrity": "sha512-rgO9Zg5LLLkfJF9E6CCmXlSE4UVceloys8JrFqCcHloC3usd/kJCyPDwH2SOlzix2j3xaP9sUX3e8+kvkuleAA==", "license": "MIT", "dependencies": { - "parse5": "^7.0.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, - "node_modules/parse5/node_modules/entities": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", - "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" + "@types/node": "*" } }, "node_modules/path-is-absolute": { @@ -1185,6 +1040,20 @@ "node": "*" } }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, "node_modules/resolve": { "version": "1.22.11", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.11.tgz", @@ -1226,12 +1095,6 @@ ], "license": "MIT" }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "license": "MIT" - }, "node_modules/semver": { "version": "5.7.2", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", @@ -1249,6 +1112,15 @@ "dev": true, "license": "BSD-3-Clause" }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, "node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", @@ -1349,14 +1221,11 @@ "node": ">=4.2.0" } }, - "node_modules/undici": { - "version": "7.16.0", - "resolved": "https://registry.npmjs.org/undici/-/undici-7.16.0.tgz", - "integrity": "sha512-QEg3HPMll0o3t2ourKwOeUAZ159Kn9mx5pnzHRQO8+Wixmh88YdZRiIwat0iNzNNXn0yoEtXJqFpyW7eM8BV7g==", - "license": "MIT", - "engines": { - "node": ">=20.18.1" - } + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "license": "MIT" }, "node_modules/uuid": { "version": "3.4.0", @@ -1438,27 +1307,6 @@ "node": ">=0.8.0" } }, - "node_modules/whatwg-encoding": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", - "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", - "license": "MIT", - "dependencies": { - "iconv-lite": "0.6.3" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/whatwg-mimetype": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", - "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", - "license": "MIT", - "engines": { - "node": ">=18" - } - }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", diff --git a/vscode/powershellprotools/package.json b/vscode/powershellprotools/package.json index 9faaeea..d3ccad7 100644 --- a/vscode/powershellprotools/package.json +++ b/vscode/powershellprotools/package.json @@ -873,7 +873,8 @@ }, "scripts": { "vscode:prepublish": "npm run compile", - "compile": "npm run check-types && npm run bundle", + "generate:vscode-api": "node ./scripts/generate-vscode-api.js", + "compile": "npm run generate:vscode-api && npm run check-types && npm run bundle", "check-types": "tsc -p ./ --noEmit", "bundle": "esbuild ./src/extension.ts --bundle --external:vscode --platform=node --format=cjs --target=node12 --outfile=out/extension.js", "lint": "eslint src --ext ts", @@ -884,14 +885,14 @@ "devDependencies": { "@types/mocha": "^2.2.42", "@types/node": "^14.11.2", - "@types/vscode": "^1.46.0", + "@types/vscode": "1.46.0", "esbuild": "^0.13.8", "tslint": "^5.8.0", "typescript": "^4.0.2" }, "dependencies": { "axios": "^0.21.1", - "cheerio": "^1.0.0-rc.2", + "cheerio": "1.0.0-rc.2", "extract-zip": "^2.0.1", "json-rpc2": "^2.0.0", "moment": "^2.28.0", @@ -913,4 +914,4 @@ "powershell", "windowsforms" ] -} \ No newline at end of file +} diff --git a/vscode/powershellprotools/scripts/generate-vscode-api.js b/vscode/powershellprotools/scripts/generate-vscode-api.js new file mode 100644 index 0000000..e64e6e3 --- /dev/null +++ b/vscode/powershellprotools/scripts/generate-vscode-api.js @@ -0,0 +1,444 @@ +/* eslint-disable no-console */ +const fs = require('fs'); +const path = require('path'); +const ts = require('typescript'); + +const root = path.resolve(__dirname, '..'); +const repoRoot = path.resolve(root, '..', '..'); +const dtsPath = require.resolve('@types/vscode/index.d.ts', { paths: [root] }); +const vscodeTypesPackage = require(require.resolve('@types/vscode/package.json', { paths: [root] })); +const source = fs.readFileSync(dtsPath, 'utf8'); +const sourceFile = ts.createSourceFile(dtsPath, source, ts.ScriptTarget.Latest, true); + +const generatedTypes = new Set(); +const interfaces = new Map(); +const classes = new Map(); +const namespaces = new Map(); +const enums = new Map(); +const metadata = {}; + +const reserved = new Set([ + 'abstract', 'as', 'base', 'bool', 'break', 'byte', 'case', 'catch', 'char', 'checked', + 'class', 'const', 'continue', 'decimal', 'default', 'delegate', 'do', 'double', 'else', + 'enum', 'event', 'explicit', 'extern', 'false', 'finally', 'fixed', 'float', 'for', + 'foreach', 'goto', 'if', 'implicit', 'in', 'int', 'interface', 'internal', 'is', 'lock', + 'long', 'namespace', 'new', 'null', 'object', 'operator', 'out', 'override', 'params', + 'private', 'protected', 'public', 'readonly', 'ref', 'return', 'sbyte', 'sealed', 'short', + 'sizeof', 'stackalloc', 'static', 'string', 'struct', 'switch', 'this', 'throw', 'true', + 'try', 'typeof', 'uint', 'ulong', 'unchecked', 'unsafe', 'ushort', 'using', 'virtual', + 'void', 'volatile', 'while' +]); + +function findVSCodeModule() { + for (const statement of sourceFile.statements) { + if (ts.isModuleDeclaration(statement) && statement.name && statement.name.text === 'vscode') { + return statement.body; + } + } + + throw new Error('Could not find declare module "vscode".'); +} + +function hasExport(node) { + return !node.modifiers || node.modifiers.some(m => m.kind === ts.SyntaxKind.ExportKeyword); +} + +function text(node) { + return node ? node.getText(sourceFile) : ''; +} + +function nameOf(node) { + if (!node || !node.name) { + return null; + } + + return node.name.getText(sourceFile).replace(/^['"]|['"]$/g, ''); +} + +function csIdentifier(name) { + if (!name) { + return name; + } + + let clean = name.replace(/[^A-Za-z0-9_]/g, '_'); + if (/^[0-9]/.test(clean)) { + clean = '_' + clean; + } + + if (reserved.has(clean)) { + return '@' + clean; + } + + return clean; +} + +function csTypeName(name) { + return `VSCode${name.replace(/[^A-Za-z0-9_]/g, '')}`; +} + +function constructorTypeName(name) { + return `${csTypeName(name)}Constructor`; +} + +function stripParens(type) { + while (type && ts.isParenthesizedTypeNode(type)) { + type = type.type; + } + + return type; +} + +function mapType(type) { + type = stripParens(type); + if (!type) { + return 'object'; + } + + if (type.kind === ts.SyntaxKind.VoidKeyword) { + return 'void'; + } + + if (type.kind === ts.SyntaxKind.StringKeyword) { + return 'string'; + } + + if (type.kind === ts.SyntaxKind.NumberKeyword) { + return 'double'; + } + + if (type.kind === ts.SyntaxKind.BooleanKeyword) { + return 'bool'; + } + + if (type.kind === ts.SyntaxKind.AnyKeyword || type.kind === ts.SyntaxKind.UnknownKeyword) { + return 'object'; + } + + if (ts.isArrayTypeNode(type)) { + const element = mapType(type.elementType); + return element === 'void' ? 'object[]' : `${element}[]`; + } + + if (ts.isUnionTypeNode(type)) { + const usable = type.types.filter(t => { + const kind = stripParens(t).kind; + return kind !== ts.SyntaxKind.NullKeyword && kind !== ts.SyntaxKind.UndefinedKeyword && kind !== ts.SyntaxKind.NeverKeyword; + }); + + if (usable.length === 1) { + return mapType(usable[0]); + } + + return 'object'; + } + + if (ts.isTypeReferenceNode(type)) { + const typeName = text(type.typeName); + const first = type.typeArguments && type.typeArguments[0]; + + if (typeName === 'Thenable' || typeName === 'Promise' || typeName === 'ProviderResult') { + return mapType(first); + } + + if (typeName === 'Array' || typeName === 'ReadonlyArray') { + const element = mapType(first); + return element === 'void' ? 'object[]' : `${element}[]`; + } + + const shortName = typeName.split('.').pop(); + if (generatedTypes.has(shortName)) { + return csTypeName(shortName); + } + + if (enums.has(shortName)) { + return csTypeName(shortName); + } + + return 'object'; + } + + return 'object'; +} + +function getMembers(node) { + const members = []; + if (!node.members) { + return members; + } + + for (const member of node.members) { + const name = nameOf(member); + if (!name) { + continue; + } + + if (ts.isPropertySignature(member) || ts.isPropertyDeclaration(member) || ts.isGetAccessor(member)) { + members.push({ kind: 'property', name, type: mapType(member.type) }); + } + else if (ts.isMethodSignature(member) || ts.isMethodDeclaration(member)) { + members.push({ kind: 'method', name, type: mapType(member.type) }); + } + } + + return members; +} + +function mergeMembers(existing, incoming) { + const seen = new Set(existing.map(m => `${m.kind}:${m.name}`)); + for (const member of incoming) { + const key = `${member.kind}:${member.name}`; + if (!seen.has(key)) { + existing.push(member); + seen.add(key); + } + } +} + +function collectTopLevel(moduleBody) { + for (const statement of moduleBody.statements) { + if (!hasExport(statement)) { + continue; + } + + if ((ts.isInterfaceDeclaration(statement) || ts.isClassDeclaration(statement)) && statement.name) { + generatedTypes.add(statement.name.text); + } + else if (ts.isEnumDeclaration(statement) && statement.name) { + generatedTypes.add(statement.name.text); + enums.set(statement.name.text, statement); + } + } + + for (const statement of moduleBody.statements) { + if (!hasExport(statement)) { + continue; + } + + if (ts.isModuleDeclaration(statement) && statement.name && statement.body && ts.isModuleBlock(statement.body)) { + const namespaceName = statement.name.text; + const existing = namespaces.get(namespaceName) || []; + collectNamespaceMembers(namespaceName, statement.body, existing); + namespaces.set(namespaceName, existing); + } + else if (ts.isInterfaceDeclaration(statement) && statement.name) { + const name = statement.name.text; + const existing = interfaces.get(name) || []; + mergeMembers(existing, getMembers(statement)); + interfaces.set(name, existing); + } + else if (ts.isClassDeclaration(statement) && statement.name) { + const name = statement.name.text; + const existing = classes.get(name) || { instance: [], statics: [], constructable: false }; + for (const member of statement.members) { + if (ts.isConstructorDeclaration(member)) { + existing.constructable = true; + continue; + } + + const memberName = nameOf(member); + if (!memberName) { + continue; + } + + const item = { + kind: (ts.isMethodDeclaration(member) || ts.isMethodSignature(member)) ? 'method' : 'property', + name: memberName, + type: mapType(member.type) + }; + + const isStatic = member.modifiers && member.modifiers.some(m => m.kind === ts.SyntaxKind.StaticKeyword); + mergeMembers(isStatic ? existing.statics : existing.instance, [item]); + } + + classes.set(name, existing); + } + } +} + +function collectNamespaceMembers(namespaceName, moduleBlock, members) { + for (const statement of moduleBlock.statements) { + if (ts.isVariableStatement(statement)) { + for (const declaration of statement.declarationList.declarations) { + const name = nameOf(declaration); + if (name) { + mergeMembers(members, [{ kind: 'property', name, type: mapType(declaration.type) }]); + } + } + } + else if (ts.isFunctionDeclaration(statement)) { + const name = nameOf(statement); + if (name) { + mergeMembers(members, [{ kind: 'method', name, type: mapType(statement.type) }]); + } + } + else if (ts.isModuleDeclaration(statement) && statement.name && statement.body && ts.isModuleBlock(statement.body)) { + const nestedName = `${namespaceName}.${statement.name.text}`; + const nested = namespaces.get(nestedName) || []; + collectNamespaceMembers(nestedName, statement.body, nested); + namespaces.set(nestedName, nested); + mergeMembers(members, [{ kind: 'property', name: statement.name.text, type: csTypeName(nestedName.replace(/\./g, '')) }]); + } + } +} + +function emitMethod(member) { + const methodName = csIdentifier(member.name); + if (member.type === 'void') { + return [ + ` public void ${methodName}(params object[] arguments)`, + ' {', + ` Invoke("${member.name}", arguments);`, + ' }' + ].join('\n'); + } + + return [ + ` public ${member.type} ${methodName}(params object[] arguments)`, + ' {', + ` return Invoke<${member.type}>("${member.name}", arguments);`, + ' }' + ].join('\n'); +} + +function emitProperty(member) { + return [ + ` public ${member.type} ${csIdentifier(member.name)}`, + ' {', + ` get { return Get<${member.type}>("${member.name}"); }`, + ' }' + ].join('\n'); +} + +function emitObjectClass(name, members, pathSegments) { + const className = csTypeName(name.replace(/\./g, '')); + const lines = [ + ` public sealed class ${className} : VSCodeObject`, + ' {', + ` internal ${className}(VSCodeProxyClient client, VSCodeProxyTarget target)`, + ' : base(client, target)', + ' {', + ' }' + ]; + + for (const member of members) { + lines.push(''); + lines.push(member.kind === 'method' ? emitMethod(member) : emitProperty(member)); + } + + lines.push(' }'); + metadata[pathSegments.join('.')] = members.map(m => m.name); + return lines.join('\n'); +} + +function emitConstructorClass(name, info) { + const className = constructorTypeName(name); + const instanceType = csTypeName(name); + const lines = [ + ` public sealed class ${className} : VSCodeObject`, + ' {', + ` internal ${className}(VSCodeProxyClient client, VSCodeProxyTarget target)`, + ' : base(client, target)', + ' {', + ' }', + '', + ` public ${instanceType} @new(params object[] arguments)`, + ' {', + ` return Construct<${instanceType}>(arguments);`, + ' }' + ]; + + for (const member of info.statics) { + lines.push(''); + lines.push(member.kind === 'method' ? emitMethod(member) : emitProperty(member)); + } + + lines.push(' }'); + metadata[name] = info.statics.map(m => m.name); + return lines.join('\n'); +} + +function emitEnum(name, declaration) { + const lines = [` public enum ${csTypeName(name)}`, ' {']; + declaration.members.forEach((member, index) => { + const memberName = csIdentifier(nameOf(member) || `Value${index}`); + let value = index; + if (member.initializer && ts.isNumericLiteral(member.initializer)) { + value = Number(member.initializer.text); + } + + lines.push(` ${memberName} = ${value},`); + }); + lines.push(' }'); + return lines.join('\n'); +} + +function emitRoot() { + const lines = [ + ' public sealed class VSCodeApi : VSCodeObject', + ' {', + ' internal VSCodeApi(VSCodeProxyClient client)', + ' : base(client, VSCodeProxyClient.Path())', + ' {', + ]; + + for (const name of Array.from(namespaces.keys()).filter(n => !n.includes('.')).sort()) { + lines.push(` ${csIdentifier(name)} = new ${csTypeName(name)}(client, VSCodeProxyClient.Path("${name}"));`); + } + + for (const name of Array.from(classes.keys()).sort()) { + lines.push(` ${csIdentifier(name)} = new ${constructorTypeName(name)}(client, VSCodeProxyClient.Path("${name}"));`); + } + + lines.push(' }'); + + for (const name of Array.from(namespaces.keys()).filter(n => !n.includes('.')).sort()) { + lines.push(''); + lines.push(` public ${csTypeName(name)} ${csIdentifier(name)} { get; }`); + } + + for (const name of Array.from(classes.keys()).sort()) { + lines.push(''); + lines.push(` public ${constructorTypeName(name)} ${csIdentifier(name)} { get; }`); + } + + lines.push(' }'); + return lines.join('\n'); +} + +collectTopLevel(findVSCodeModule()); + +const csharp = [ + '// ', + 'namespace PowerShellToolsPro.Cmdlets.VSCode', + '{', + emitRoot(), + '', + ...Array.from(enums.entries()).sort(([a], [b]) => a.localeCompare(b)).map(([name, declaration]) => emitEnum(name, declaration)), + ...Array.from(namespaces.entries()).sort(([a], [b]) => a.localeCompare(b)).map(([name, members]) => emitObjectClass(name, members, name.split('.'))), + ...Array.from(interfaces.entries()).sort(([a], [b]) => a.localeCompare(b)).map(([name, members]) => emitObjectClass(name, members, [name])), + ...Array.from(classes.entries()).sort(([a], [b]) => a.localeCompare(b)).flatMap(([name, info]) => [ + emitObjectClass(name, info.instance, [name]), + emitConstructorClass(name, info) + ]), + '}', + '' +].join('\n\n'); + +const csharpPath = path.resolve(repoRoot, 'HostInjection', 'Generated', 'VSCodeApi.g.cs'); +fs.mkdirSync(path.dirname(csharpPath), { recursive: true }); +fs.writeFileSync(csharpPath, csharp); + +const metadataSource = [ + '// ', + 'export const vscodeApiMetadata: { version: string; members: { [path: string]: string[] } } = {', + ` version: ${JSON.stringify(vscodeTypesPackage.version)},`, + ` members: ${JSON.stringify(metadata, null, 4)}`, + '};', + '' +].join('\n'); + +const metadataPath = path.resolve(root, 'src', 'generated', 'vscodeApiMetadata.ts'); +fs.mkdirSync(path.dirname(metadataPath), { recursive: true }); +fs.writeFileSync(metadataPath, metadataSource); + +console.log(`Generated VS Code API surface from @types/vscode ${vscodeTypesPackage.version}.`); diff --git a/vscode/powershellprotools/src/extension.ts b/vscode/powershellprotools/src/extension.ts index 7d3225e..061c4cb 100644 --- a/vscode/powershellprotools/src/extension.ts +++ b/vscode/powershellprotools/src/extension.ts @@ -94,7 +94,7 @@ export async function activate(context: vscode.ExtensionContext) { await extension.activate(); const powerShellExtensionClient = extension!.exports as IPowerShellExtensionClient; - const id = powerShellExtensionClient.registerExternalExtension(context.extension.id); + const id = powerShellExtensionClient.registerExternalExtension("ironmansoftware.powershellprotools"); context.subscriptions.push({ dispose: () => powerShellExtensionClient.unregisterExternalExtension(id) }); diff --git a/vscode/powershellprotools/src/generated/vscodeApiMetadata.ts b/vscode/powershellprotools/src/generated/vscodeApiMetadata.ts new file mode 100644 index 0000000..da5f625 --- /dev/null +++ b/vscode/powershellprotools/src/generated/vscodeApiMetadata.ts @@ -0,0 +1,1227 @@ +// +export const vscodeApiMetadata: { version: string; members: { [path: string]: string[] } } = { + version: "1.46.0", + members: { + "commands": [ + "registerCommand", + "registerTextEditorCommand", + "executeCommand", + "getCommands" + ], + "comments": [ + "createCommentController" + ], + "debug": [ + "activeDebugSession", + "activeDebugConsole", + "breakpoints", + "onDidChangeActiveDebugSession", + "onDidStartDebugSession", + "onDidReceiveDebugSessionCustomEvent", + "onDidTerminateDebugSession", + "onDidChangeBreakpoints", + "registerDebugConfigurationProvider", + "registerDebugAdapterDescriptorFactory", + "registerDebugAdapterTrackerFactory", + "startDebugging", + "addBreakpoints", + "removeBreakpoints", + "asDebugSourceUri" + ], + "env": [ + "appName", + "appRoot", + "uriScheme", + "language", + "clipboard", + "machineId", + "sessionId", + "remoteName", + "shell", + "uiKind", + "openExternal", + "asExternalUri" + ], + "extensions": [ + "getExtension", + "all", + "onDidChange" + ], + "languages": [ + "getLanguages", + "setTextDocumentLanguage", + "match", + "onDidChangeDiagnostics", + "getDiagnostics", + "createDiagnosticCollection", + "registerCompletionItemProvider", + "registerCodeActionsProvider", + "registerCodeLensProvider", + "registerDefinitionProvider", + "registerImplementationProvider", + "registerTypeDefinitionProvider", + "registerDeclarationProvider", + "registerHoverProvider", + "registerEvaluatableExpressionProvider", + "registerDocumentHighlightProvider", + "registerDocumentSymbolProvider", + "registerWorkspaceSymbolProvider", + "registerReferenceProvider", + "registerRenameProvider", + "registerDocumentSemanticTokensProvider", + "registerDocumentRangeSemanticTokensProvider", + "registerDocumentFormattingEditProvider", + "registerDocumentRangeFormattingEditProvider", + "registerOnTypeFormattingEditProvider", + "registerSignatureHelpProvider", + "registerDocumentLinkProvider", + "registerColorProvider", + "registerFoldingRangeProvider", + "registerSelectionRangeProvider", + "registerCallHierarchyProvider", + "setLanguageConfiguration" + ], + "scm": [ + "inputBox", + "createSourceControl" + ], + "tasks": [ + "registerTaskProvider", + "fetchTasks", + "executeTask", + "taskExecutions", + "onDidStartTask", + "onDidEndTask", + "onDidStartTaskProcess", + "onDidEndTaskProcess" + ], + "window": [ + "activeTextEditor", + "visibleTextEditors", + "onDidChangeActiveTextEditor", + "onDidChangeVisibleTextEditors", + "onDidChangeTextEditorSelection", + "onDidChangeTextEditorVisibleRanges", + "onDidChangeTextEditorOptions", + "onDidChangeTextEditorViewColumn", + "terminals", + "activeTerminal", + "onDidChangeActiveTerminal", + "onDidOpenTerminal", + "onDidCloseTerminal", + "state", + "onDidChangeWindowState", + "showTextDocument", + "createTextEditorDecorationType", + "showInformationMessage", + "showWarningMessage", + "showErrorMessage", + "showQuickPick", + "showWorkspaceFolderPick", + "showOpenDialog", + "showSaveDialog", + "showInputBox", + "createQuickPick", + "createInputBox", + "createOutputChannel", + "createWebviewPanel", + "setStatusBarMessage", + "withScmProgress", + "withProgress", + "createStatusBarItem", + "createTerminal", + "registerTreeDataProvider", + "createTreeView", + "registerUriHandler", + "registerWebviewPanelSerializer", + "registerCustomEditorProvider", + "activeColorTheme", + "onDidChangeActiveColorTheme" + ], + "workspace": [ + "fs", + "rootPath", + "workspaceFolders", + "name", + "workspaceFile", + "onDidChangeWorkspaceFolders", + "getWorkspaceFolder", + "asRelativePath", + "updateWorkspaceFolders", + "createFileSystemWatcher", + "findFiles", + "saveAll", + "applyEdit", + "textDocuments", + "openTextDocument", + "registerTextDocumentContentProvider", + "onDidOpenTextDocument", + "onDidCloseTextDocument", + "onDidChangeTextDocument", + "onWillSaveTextDocument", + "onDidSaveTextDocument", + "onWillCreateFiles", + "onDidCreateFiles", + "onWillDeleteFiles", + "onDidDeleteFiles", + "onWillRenameFiles", + "onDidRenameFiles", + "getConfiguration", + "onDidChangeConfiguration", + "registerTaskProvider", + "registerFileSystemProvider" + ], + "BreakpointsChangeEvent": [ + "added", + "removed", + "changed" + ], + "CallHierarchyProvider": [ + "prepareCallHierarchy", + "provideCallHierarchyIncomingCalls", + "provideCallHierarchyOutgoingCalls" + ], + "CancellationToken": [ + "isCancellationRequested", + "onCancellationRequested" + ], + "Clipboard": [ + "readText", + "writeText" + ], + "CodeActionContext": [ + "diagnostics", + "only" + ], + "CodeActionProvider": [ + "provideCodeActions" + ], + "CodeActionProviderMetadata": [ + "providedCodeActionKinds" + ], + "CodeLensProvider": [ + "onDidChangeCodeLenses", + "provideCodeLenses", + "resolveCodeLens" + ], + "ColorTheme": [ + "kind" + ], + "Command": [ + "title", + "command", + "tooltip", + "arguments" + ], + "Comment": [ + "body", + "mode", + "author", + "contextValue", + "reactions", + "label" + ], + "CommentAuthorInformation": [ + "name", + "iconPath" + ], + "CommentController": [ + "id", + "label", + "options", + "commentingRangeProvider", + "createCommentThread", + "reactionHandler", + "dispose" + ], + "CommentingRangeProvider": [ + "provideCommentingRanges" + ], + "CommentOptions": [ + "prompt", + "placeHolder" + ], + "CommentReaction": [ + "label", + "iconPath", + "count", + "authorHasReacted" + ], + "CommentReply": [ + "thread", + "text" + ], + "CommentRule": [ + "lineComment", + "blockComment" + ], + "CommentThread": [ + "uri", + "range", + "comments", + "collapsibleState", + "contextValue", + "label", + "dispose" + ], + "CompletionContext": [ + "triggerKind", + "triggerCharacter" + ], + "CompletionItemProvider": [ + "provideCompletionItems", + "resolveCompletionItem" + ], + "ConfigurationChangeEvent": [ + "affectsConfiguration" + ], + "CustomDocument": [ + "uri", + "dispose" + ], + "CustomDocumentBackup": [ + "id", + "delete" + ], + "CustomDocumentBackupContext": [ + "destination" + ], + "CustomDocumentContentChangeEvent": [ + "document" + ], + "CustomDocumentEditEvent": [ + "document", + "undo", + "redo", + "label" + ], + "CustomDocumentOpenContext": [ + "backupId" + ], + "CustomEditorProvider": [ + "onDidChangeCustomDocument", + "saveCustomDocument", + "saveCustomDocumentAs", + "revertCustomDocument", + "backupCustomDocument" + ], + "CustomReadonlyEditorProvider": [ + "openCustomDocument", + "resolveCustomEditor" + ], + "CustomTextEditorProvider": [ + "resolveCustomTextEditor" + ], + "DebugAdapter": [ + "onDidSendMessage", + "handleMessage" + ], + "DebugAdapterDescriptorFactory": [ + "createDebugAdapterDescriptor" + ], + "DebugAdapterExecutableOptions": [ + "env", + "cwd" + ], + "DebugAdapterTracker": [ + "onWillStartSession", + "onWillReceiveMessage", + "onDidSendMessage", + "onWillStopSession", + "onError", + "onExit" + ], + "DebugAdapterTrackerFactory": [ + "createDebugAdapterTracker" + ], + "DebugConfiguration": [ + "type", + "name", + "request" + ], + "DebugConfigurationProvider": [ + "provideDebugConfigurations", + "resolveDebugConfiguration", + "resolveDebugConfigurationWithSubstitutedVariables" + ], + "DebugConsole": [ + "append", + "appendLine" + ], + "DebugProtocolMessage": [], + "DebugProtocolSource": [], + "DebugSession": [ + "id", + "type", + "name", + "workspaceFolder", + "configuration", + "customRequest" + ], + "DebugSessionCustomEvent": [ + "session", + "event", + "body" + ], + "DebugSessionOptions": [ + "parentSession", + "consoleMode" + ], + "DeclarationProvider": [ + "provideDeclaration" + ], + "DecorationInstanceRenderOptions": [ + "light", + "dark" + ], + "DecorationOptions": [ + "range", + "hoverMessage", + "renderOptions" + ], + "DecorationRenderOptions": [ + "isWholeLine", + "rangeBehavior", + "overviewRulerLane", + "light", + "dark" + ], + "DefinitionProvider": [ + "provideDefinition" + ], + "DiagnosticChangeEvent": [ + "uris" + ], + "DiagnosticCollection": [ + "name", + "set", + "delete", + "clear", + "forEach", + "get", + "has", + "dispose" + ], + "DocumentColorProvider": [ + "provideDocumentColors", + "provideColorPresentations" + ], + "DocumentFilter": [ + "language", + "scheme", + "pattern" + ], + "DocumentFormattingEditProvider": [ + "provideDocumentFormattingEdits" + ], + "DocumentHighlightProvider": [ + "provideDocumentHighlights" + ], + "DocumentLinkProvider": [ + "provideDocumentLinks", + "resolveDocumentLink" + ], + "DocumentRangeFormattingEditProvider": [ + "provideDocumentRangeFormattingEdits" + ], + "DocumentRangeSemanticTokensProvider": [ + "provideDocumentRangeSemanticTokens" + ], + "DocumentSemanticTokensProvider": [ + "onDidChangeSemanticTokens", + "provideDocumentSemanticTokens", + "provideDocumentSemanticTokensEdits" + ], + "DocumentSymbolProvider": [ + "provideDocumentSymbols" + ], + "DocumentSymbolProviderMetadata": [ + "label" + ], + "EnterAction": [ + "indentAction", + "appendText", + "removeText" + ], + "EnvironmentVariableCollection": [ + "persistent", + "replace", + "append", + "prepend", + "get", + "forEach", + "delete", + "clear" + ], + "EnvironmentVariableMutator": [ + "type", + "value" + ], + "EvaluatableExpressionProvider": [ + "provideEvaluatableExpression" + ], + "Event": [], + "Extension": [ + "id", + "extensionUri", + "extensionPath", + "isActive", + "packageJSON", + "extensionKind", + "exports", + "activate" + ], + "ExtensionContext": [ + "subscriptions", + "workspaceState", + "globalState", + "extensionUri", + "extensionPath", + "environmentVariableCollection", + "asAbsolutePath", + "storagePath", + "globalStoragePath", + "logPath" + ], + "ExtensionTerminalOptions": [ + "name", + "pty" + ], + "FileChangeEvent": [ + "type", + "uri" + ], + "FileCreateEvent": [ + "files" + ], + "FileDeleteEvent": [ + "files" + ], + "FileRenameEvent": [ + "files" + ], + "FileStat": [ + "type", + "ctime", + "mtime", + "size" + ], + "FileSystem": [ + "stat", + "readDirectory", + "createDirectory", + "readFile", + "writeFile", + "delete", + "rename", + "copy" + ], + "FileSystemProvider": [ + "onDidChangeFile", + "watch", + "stat", + "readDirectory", + "createDirectory", + "readFile", + "writeFile", + "delete", + "rename", + "copy" + ], + "FileSystemWatcher": [ + "ignoreCreateEvents", + "ignoreChangeEvents", + "ignoreDeleteEvents", + "onDidCreate", + "onDidChange", + "onDidDelete" + ], + "FileWillCreateEvent": [ + "files", + "waitUntil" + ], + "FileWillDeleteEvent": [ + "files", + "waitUntil" + ], + "FileWillRenameEvent": [ + "files", + "waitUntil" + ], + "FoldingContext": [], + "FoldingRangeProvider": [ + "provideFoldingRanges" + ], + "FormattingOptions": [ + "tabSize", + "insertSpaces" + ], + "HoverProvider": [ + "provideHover" + ], + "ImplementationProvider": [ + "provideImplementation" + ], + "IndentationRule": [ + "decreaseIndentPattern", + "increaseIndentPattern", + "indentNextLinePattern", + "unIndentedLinePattern" + ], + "InputBox": [ + "value", + "placeholder", + "password", + "onDidChangeValue", + "onDidAccept", + "buttons", + "onDidTriggerButton", + "prompt", + "validationMessage" + ], + "InputBoxOptions": [ + "value", + "valueSelection", + "prompt", + "placeHolder", + "password", + "ignoreFocusOut", + "validateInput" + ], + "LanguageConfiguration": [ + "comments", + "brackets", + "wordPattern", + "indentationRules", + "onEnterRules", + "__electricCharacterSupport", + "__characterPairSupport" + ], + "LocationLink": [ + "originSelectionRange", + "targetUri", + "targetRange", + "targetSelectionRange" + ], + "Memento": [ + "get", + "update" + ], + "MessageItem": [ + "title", + "isCloseAffordance" + ], + "MessageOptions": [ + "modal" + ], + "OnEnterRule": [ + "beforeText", + "afterText", + "action" + ], + "OnTypeFormattingEditProvider": [ + "provideOnTypeFormattingEdits" + ], + "OpenDialogOptions": [ + "defaultUri", + "openLabel", + "canSelectFiles", + "canSelectFolders", + "canSelectMany", + "filters" + ], + "OutputChannel": [ + "name", + "append", + "appendLine", + "clear", + "show", + "hide", + "dispose" + ], + "ProcessExecutionOptions": [ + "cwd", + "env" + ], + "Progress": [ + "report" + ], + "ProgressOptions": [ + "location", + "title", + "cancellable" + ], + "Pseudoterminal": [ + "onDidWrite", + "onDidOverrideDimensions", + "onDidClose", + "open", + "close", + "handleInput", + "setDimensions" + ], + "QuickDiffProvider": [ + "provideOriginalResource" + ], + "QuickInput": [ + "title", + "step", + "totalSteps", + "enabled", + "busy", + "ignoreFocusOut", + "show", + "hide", + "onDidHide", + "dispose" + ], + "QuickInputButton": [ + "iconPath", + "tooltip" + ], + "QuickPick": [ + "value", + "placeholder", + "onDidChangeValue", + "onDidAccept", + "buttons", + "onDidTriggerButton", + "items", + "canSelectMany", + "matchOnDescription", + "matchOnDetail", + "activeItems", + "onDidChangeActive", + "selectedItems", + "onDidChangeSelection" + ], + "QuickPickItem": [ + "label", + "description", + "detail", + "picked", + "alwaysShow" + ], + "QuickPickOptions": [ + "matchOnDescription", + "matchOnDetail", + "placeHolder", + "ignoreFocusOut", + "canPickMany", + "onDidSelectItem" + ], + "ReferenceContext": [ + "includeDeclaration" + ], + "ReferenceProvider": [ + "provideReferences" + ], + "RenameProvider": [ + "provideRenameEdits", + "prepareRename" + ], + "RunOptions": [ + "reevaluateOnRerun" + ], + "SaveDialogOptions": [ + "defaultUri", + "saveLabel", + "filters" + ], + "SelectionRangeProvider": [ + "provideSelectionRanges" + ], + "ShellExecutionOptions": [ + "executable", + "shellArgs", + "shellQuoting", + "cwd", + "env" + ], + "ShellQuotedString": [ + "value", + "quoting" + ], + "ShellQuotingOptions": [ + "escape", + "strong", + "weak" + ], + "SignatureHelpContext": [ + "triggerKind", + "triggerCharacter", + "isRetrigger", + "activeSignatureHelp" + ], + "SignatureHelpProvider": [ + "provideSignatureHelp" + ], + "SignatureHelpProviderMetadata": [ + "triggerCharacters", + "retriggerCharacters" + ], + "SourceControl": [ + "id", + "label", + "rootUri", + "inputBox", + "count", + "quickDiffProvider", + "commitTemplate", + "acceptInputCommand", + "statusBarCommands", + "createResourceGroup", + "dispose" + ], + "SourceControlInputBox": [ + "value", + "placeholder", + "visible" + ], + "SourceControlResourceDecorations": [ + "strikeThrough", + "faded", + "tooltip", + "light", + "dark" + ], + "SourceControlResourceGroup": [ + "id", + "label", + "hideWhenEmpty", + "resourceStates", + "dispose" + ], + "SourceControlResourceState": [ + "resourceUri", + "command", + "decorations" + ], + "SourceControlResourceThemableDecorations": [ + "iconPath" + ], + "StatusBarItem": [ + "alignment", + "priority", + "text", + "tooltip", + "color", + "command", + "show", + "hide", + "dispose" + ], + "TaskDefinition": [ + "type" + ], + "TaskEndEvent": [ + "execution" + ], + "TaskExecution": [ + "task", + "terminate" + ], + "TaskFilter": [ + "version", + "type" + ], + "TaskPresentationOptions": [ + "reveal", + "echo", + "focus", + "panel", + "showReuseMessage", + "clear" + ], + "TaskProcessEndEvent": [ + "execution", + "exitCode" + ], + "TaskProcessStartEvent": [ + "execution", + "processId" + ], + "TaskProvider": [ + "provideTasks", + "resolveTask" + ], + "TaskStartEvent": [ + "execution" + ], + "Terminal": [ + "name", + "processId", + "creationOptions", + "exitStatus", + "sendText", + "show", + "hide", + "dispose" + ], + "TerminalDimensions": [ + "columns", + "rows" + ], + "TerminalExitStatus": [ + "code" + ], + "TerminalOptions": [ + "name", + "shellPath", + "shellArgs", + "cwd", + "env", + "strictEnv", + "hideFromUser" + ], + "TextDocument": [ + "uri", + "fileName", + "isUntitled", + "languageId", + "version", + "isDirty", + "isClosed", + "save", + "eol", + "lineCount", + "lineAt", + "offsetAt", + "positionAt", + "getText", + "getWordRangeAtPosition", + "validateRange", + "validatePosition" + ], + "TextDocumentChangeEvent": [ + "document", + "contentChanges" + ], + "TextDocumentContentChangeEvent": [ + "range", + "rangeOffset", + "rangeLength", + "text" + ], + "TextDocumentContentProvider": [ + "onDidChange", + "provideTextDocumentContent" + ], + "TextDocumentShowOptions": [ + "viewColumn", + "preserveFocus", + "preview", + "selection" + ], + "TextDocumentWillSaveEvent": [ + "document", + "reason", + "waitUntil" + ], + "TextEditor": [ + "document", + "selection", + "selections", + "visibleRanges", + "options", + "viewColumn", + "edit", + "insertSnippet", + "setDecorations", + "revealRange", + "show", + "hide" + ], + "TextEditorDecorationType": [ + "key", + "dispose" + ], + "TextEditorEdit": [ + "replace", + "insert", + "delete", + "setEndOfLine" + ], + "TextEditorOptions": [ + "tabSize", + "insertSpaces", + "cursorStyle", + "lineNumbers" + ], + "TextEditorOptionsChangeEvent": [ + "textEditor", + "options" + ], + "TextEditorSelectionChangeEvent": [ + "textEditor", + "selections", + "kind" + ], + "TextEditorViewColumnChangeEvent": [ + "textEditor", + "viewColumn" + ], + "TextEditorVisibleRangesChangeEvent": [ + "textEditor", + "visibleRanges" + ], + "TextLine": [ + "lineNumber", + "text", + "range", + "rangeIncludingLineBreak", + "firstNonWhitespaceCharacterIndex", + "isEmptyOrWhitespace" + ], + "ThemableDecorationAttachmentRenderOptions": [ + "contentText", + "contentIconPath", + "border", + "borderColor", + "fontStyle", + "fontWeight", + "textDecoration", + "color", + "backgroundColor", + "margin", + "width", + "height" + ], + "ThemableDecorationInstanceRenderOptions": [ + "before", + "after" + ], + "ThemableDecorationRenderOptions": [ + "backgroundColor", + "outline", + "outlineColor", + "outlineStyle", + "outlineWidth", + "border", + "borderColor", + "borderRadius", + "borderSpacing", + "borderStyle", + "borderWidth", + "fontStyle", + "fontWeight", + "textDecoration", + "cursor", + "color", + "opacity", + "letterSpacing", + "gutterIconPath", + "gutterIconSize", + "overviewRulerColor", + "before", + "after" + ], + "TreeDataProvider": [ + "onDidChangeTreeData", + "getTreeItem", + "getChildren", + "getParent" + ], + "TreeView": [ + "onDidExpandElement", + "onDidCollapseElement", + "selection", + "onDidChangeSelection", + "visible", + "onDidChangeVisibility", + "message", + "title", + "reveal" + ], + "TreeViewExpansionEvent": [ + "element" + ], + "TreeViewOptions": [ + "treeDataProvider", + "showCollapseAll", + "canSelectMany" + ], + "TreeViewSelectionChangeEvent": [ + "selection" + ], + "TreeViewVisibilityChangeEvent": [ + "visible" + ], + "TypeDefinitionProvider": [ + "provideTypeDefinition" + ], + "UriHandler": [ + "handleUri" + ], + "Webview": [ + "options", + "html", + "onDidReceiveMessage", + "postMessage", + "asWebviewUri", + "cspSource" + ], + "WebviewOptions": [ + "enableScripts", + "enableCommandUris", + "localResourceRoots", + "portMapping" + ], + "WebviewPanel": [ + "viewType", + "title", + "iconPath", + "webview", + "options", + "viewColumn", + "active", + "visible", + "onDidChangeViewState", + "onDidDispose", + "reveal", + "dispose" + ], + "WebviewPanelOnDidChangeViewStateEvent": [ + "webviewPanel" + ], + "WebviewPanelOptions": [ + "enableFindWidget", + "retainContextWhenHidden" + ], + "WebviewPanelSerializer": [ + "deserializeWebviewPanel" + ], + "WebviewPortMapping": [ + "webviewPort", + "extensionHostPort" + ], + "WindowState": [ + "focused" + ], + "WorkspaceConfiguration": [ + "get", + "has", + "inspect", + "update" + ], + "WorkspaceEditEntryMetadata": [ + "needsConfirmation", + "label", + "description", + "iconPath" + ], + "WorkspaceFolder": [ + "uri", + "name", + "index" + ], + "WorkspaceFolderPickOptions": [ + "placeHolder", + "ignoreFocusOut" + ], + "WorkspaceFoldersChangeEvent": [ + "added", + "removed" + ], + "WorkspaceSymbolProvider": [ + "provideWorkspaceSymbols", + "resolveWorkspaceSymbol" + ], + "Breakpoint": [], + "CallHierarchyIncomingCall": [], + "CallHierarchyItem": [], + "CallHierarchyOutgoingCall": [], + "CancellationTokenSource": [], + "CodeAction": [], + "CodeActionKind": [ + "Empty", + "QuickFix", + "Refactor", + "RefactorExtract", + "RefactorInline", + "RefactorRewrite", + "Source", + "SourceOrganizeImports", + "SourceFixAll" + ], + "CodeLens": [], + "Color": [], + "ColorInformation": [], + "ColorPresentation": [], + "CompletionItem": [], + "CompletionList": [], + "CustomExecution": [], + "DebugAdapterExecutable": [], + "DebugAdapterInlineImplementation": [], + "DebugAdapterServer": [], + "Diagnostic": [], + "DiagnosticRelatedInformation": [], + "Disposable": [ + "from" + ], + "DocumentHighlight": [], + "DocumentLink": [], + "DocumentSymbol": [], + "EvaluatableExpression": [], + "EventEmitter": [], + "FileSystemError": [ + "FileNotFound", + "FileExists", + "FileNotADirectory", + "FileIsADirectory", + "NoPermissions", + "Unavailable" + ], + "FoldingRange": [], + "FunctionBreakpoint": [], + "Hover": [], + "Location": [], + "MarkdownString": [], + "ParameterInformation": [], + "Position": [], + "ProcessExecution": [], + "QuickInputButtons": [ + "Back" + ], + "Range": [], + "RelativePattern": [], + "Selection": [], + "SelectionRange": [], + "SemanticTokens": [], + "SemanticTokensBuilder": [], + "SemanticTokensEdit": [], + "SemanticTokensEdits": [], + "SemanticTokensLegend": [], + "ShellExecution": [], + "SignatureHelp": [], + "SignatureInformation": [], + "SnippetString": [], + "SourceBreakpoint": [], + "SymbolInformation": [], + "Task": [], + "TaskGroup": [ + "Clean", + "Build", + "Rebuild", + "Test" + ], + "TextEdit": [ + "replace", + "insert", + "delete", + "setEndOfLine" + ], + "ThemeColor": [], + "ThemeIcon": [ + "File", + "Folder" + ], + "TreeItem": [], + "Uri": [ + "parse", + "file", + "joinPath" + ], + "WorkspaceEdit": [] +} +}; diff --git a/vscode/powershellprotools/src/services/vscodeApiDispatcher.ts b/vscode/powershellprotools/src/services/vscodeApiDispatcher.ts new file mode 100644 index 0000000..64e5401 --- /dev/null +++ b/vscode/powershellprotools/src/services/vscodeApiDispatcher.ts @@ -0,0 +1,253 @@ +import * as vscode from 'vscode'; +import { Container } from '../container'; +import { vscodeApiMetadata } from '../generated/vscodeApiMetadata'; + +type Operation = 'get' | 'invoke' | 'construct' | 'release'; + +interface ApiTarget { + path?: string[]; + handle?: number; + typeName?: string; +} + +interface ApiArgument { + kind: 'null' | 'primitive' | 'target' | 'value'; + value?: any; + handle?: number; + path?: string[]; +} + +interface ApiRequest { + protocol: 'vscode-api'; + id: string; + operation: Operation; + target?: ApiTarget; + member?: string; + arguments?: ApiArgument[]; +} + +interface ApiResult { + kind: 'primitive' | 'array' | 'handle' | 'null' | 'undefined'; + value?: any; + handle?: number; + typeName?: string; + items?: ApiResult[]; +} + +interface ApiResponse { + id: string; + success: boolean; + error?: string; + result?: ApiResult; +} + +export class VSCodeApiDispatcher { + private handles: Map = new Map(); + private nextHandle = 1; + + async dispatch(request: ApiRequest): Promise { + try { + Container.Log(`VS Code API ${request.operation}: ${this.describeTarget(request.target)}${request.member ? `.${request.member}` : ''}`); + const result = await this.execute(request); + const serialized = await this.serializeResult(result); + Container.Log(`VS Code API result: ${serialized.kind}${serialized.typeName ? ` ${serialized.typeName}` : ''}${serialized.value !== undefined ? ` ${serialized.value}` : ''}`); + return this.createResponse(request.id, true, serialized); + } + catch (error) { + const message = error instanceof Error ? error.message : `${error}`; + Container.Log(`VS Code API error: ${error instanceof Error ? error.stack || error.message : error}`); + return this.createResponse(request.id, false, undefined, message); + } + } + + private createResponse(id: string, success: boolean, result?: ApiResult, error?: string): ApiResponse { + const response: any = { + id, + success, + error, + result, + Id: id, + Success: success, + Error: error, + Result: this.createPascalResult(result) + }; + + return response; + } + + private createPascalResult(result?: ApiResult): any { + if (!result) { + return undefined; + } + + return { + kind: result.kind, + value: result.value, + handle: result.handle, + typeName: result.typeName, + items: result.items, + Kind: result.kind, + Value: result.value, + Handle: result.handle, + TypeName: result.typeName, + Items: result.items ? result.items.map(item => this.createPascalResult(item)) : undefined + }; + } + + private async execute(request: ApiRequest): Promise { + if (request.operation === 'release') { + if (request.target && request.target.handle) { + this.handles.delete(request.target.handle); + } + + return null; + } + + const target = this.resolveTarget(request.target); + const args = (request.arguments || []).map(arg => this.deserializeArgument(arg)); + + switch (request.operation) { + case 'get': + return request.member ? target[request.member] : target; + case 'invoke': + if (!request.member) { + throw new Error('Invoke requests require a member name.'); + } + + if (!this.isKnownMember(request.target, request.member)) { + throw new Error(`VS Code API member is not in the generated surface: ${request.member}`); + } + + if (typeof target[request.member] !== 'function') { + throw new Error(`VS Code API member is not invokable: ${request.member}`); + } + + return target[request.member](...args); + case 'construct': + if (typeof target !== 'function') { + throw new Error('Construct target is not a constructor.'); + } + + return new target(...args); + default: + throw new Error(`Unsupported VS Code API operation: ${request.operation}`); + } + } + + private resolveTarget(target?: ApiTarget): any { + if (!target) { + return vscode; + } + + if (target.handle) { + if (!this.handles.has(target.handle)) { + throw new Error(`Unknown VS Code API object handle: ${target.handle}`); + } + + return this.handles.get(target.handle); + } + + let current: any = vscode; + for (const segment of target.path || []) { + if (current == null || !(segment in current)) { + throw new Error(`VS Code API path was not found: vscode.${(target.path || []).join('.')}`); + } + + current = current[segment]; + } + + return current; + } + + private deserializeArgument(argument: ApiArgument): any { + if (!argument || argument.kind === 'null') { + return null; + } + + if (argument.kind === 'target') { + return this.resolveTarget({ + handle: argument.handle, + path: argument.path + }); + } + + return argument.value; + } + + private async serializeResult(value: any): Promise { + value = await this.resolveThenable(value); + + if (value === undefined) { + return { kind: 'undefined' }; + } + + if (value === null) { + return { kind: 'null' }; + } + + if (Array.isArray(value)) { + const items = []; + for (const item of value) { + items.push(await this.serializeResult(item)); + } + + return { kind: 'array', items }; + } + + const valueType = typeof value; + if (valueType === 'string' || valueType === 'number' || valueType === 'boolean') { + return { kind: 'primitive', value }; + } + + return { + kind: 'handle', + handle: this.createHandle(value), + typeName: this.getTypeName(value) + }; + } + + private async resolveThenable(value: any): Promise { + if (value && typeof value.then === 'function') { + return await value; + } + + return value; + } + + private createHandle(value: any): number { + const handle = this.nextHandle++; + this.handles.set(handle, value); + return handle; + } + + private getTypeName(value: any): string { + if (value && value.constructor && value.constructor.name) { + return value.constructor.name; + } + + return 'Object'; + } + + private isKnownMember(target: ApiTarget, member: string): boolean { + if (!target || target.handle) { + return true; + } + + const path = target.path || []; + const key = path.join('.'); + const members = vscodeApiMetadata.members[key]; + return !members || members.indexOf(member) !== -1; + } + + private describeTarget(target?: ApiTarget): string { + if (!target) { + return 'vscode'; + } + + if (target.handle) { + return `handle:${target.handle}`; + } + + return `vscode.${(target.path || []).join('.')}`; + } +} diff --git a/vscode/powershellprotools/src/services/vscodeService.ts b/vscode/powershellprotools/src/services/vscodeService.ts index de38020..3146be3 100644 --- a/vscode/powershellprotools/src/services/vscodeService.ts +++ b/vscode/powershellprotools/src/services/vscodeService.ts @@ -3,14 +3,17 @@ import net = require('net'); import { Container } from '../container'; var fs = require('fs') import * as path from 'path'; +import { VSCodeApiDispatcher } from './vscodeApiDispatcher'; export default class VSCodeService { server: net.Server; decorations: any; + apiDispatcher: VSCodeApiDispatcher; init() { this.decorations = {} + this.apiDispatcher = new VSCodeApiDispatcher(); var _this = this; var data = ''; @@ -32,6 +35,14 @@ export default class VSCodeService { try { const msg = JSON.parse(data); + if (msg.protocol === 'vscode-api' || msg.Protocol === 'vscode-api') { + _this.apiDispatcher.dispatch(_this.normalizeApiRequest(msg)).then(response => { + stream.write(JSON.stringify(response)); + stream.end(); + }); + return; + } + _this.processMsg(msg, (s) => { if (s && s !== '') { stream.write(s); @@ -64,6 +75,29 @@ export default class VSCodeService { }); } + normalizeApiRequest(msg: any): any { + const target = msg.target || msg.Target; + const args = msg.arguments || msg.Arguments; + + return { + protocol: msg.protocol || msg.Protocol, + id: msg.id || msg.Id, + operation: msg.operation || msg.Operation, + target: target ? { + path: target.path || target.Path, + handle: target.handle || target.Handle, + typeName: target.typeName || target.TypeName + } : undefined, + member: msg.member || msg.Member, + arguments: args ? args.map(arg => ({ + kind: arg.kind || arg.Kind, + value: arg.value === undefined ? arg.Value : arg.value, + handle: arg.handle || arg.Handle, + path: arg.path || arg.Path + })) : [] + }; + } + convertToPosition(position) { return new vscode.Position(position._line, position._character); } @@ -348,6 +382,12 @@ export default class VSCodeService { terminal.sendText(msg.args.text, msg.args.addNewLine); callback('{}'); break; + default: + callback(JSON.stringify({ + success: false, + error: `Unsupported VS Code bridge message: ${msg.type || msg.Protocol || msg.protocol || ''}` + })); + break; } } -} \ No newline at end of file +} diff --git a/vscode/vscode.build.ps1 b/vscode/vscode.build.ps1 index f80fc2f..cbcefef 100644 --- a/vscode/vscode.build.ps1 +++ b/vscode/vscode.build.ps1 @@ -25,11 +25,23 @@ task Clean { New-Item (Join-Path $RootDir "out") -ItemType Directory -ErrorAction SilentlyContinue } -task Init { - if ($null -eq (Get-Module VSSetup -ListAvailable)) { - Install-Module VSSetup -Scope CurrentUser -Force -ErrorAction SilentlyContinue - } -} +task Init { + if ($null -eq (Get-Module VSSetup -ListAvailable)) { + Install-Module VSSetup -Scope CurrentUser -Force -ErrorAction SilentlyContinue + } +} + +task InstallExtensionDependencies { + Push-Location $RootDir + npm install + Pop-Location +} + +task GenerateVSCodeApi InstallExtensionDependencies, { + Push-Location $RootDir + npm run generate:vscode-api + Pop-Location +} task BuildWinFormDesigner { $instance = Get-VSSetupInstance -All -Prerelease | Select-VSSetupInstance -Require 'Microsoft.Component.MSBuild' -Latest @@ -57,24 +69,23 @@ task BuildCmdlets { Pop-Location } -task BuildExtension { - Push-Location $RootDir - & { - $ErrorActionPreference = 'SilentlyContinue' - npm install -g npm - npm install -g typescript@latest - npm install -g @vscode/vsce - npm install - - vsce package - - Move-Item (Join-Path $RootDir "*.vsix") (Join-Path $RootDir "kit") +task BuildExtension { + Push-Location $RootDir + & { + $ErrorActionPreference = 'SilentlyContinue' + npm install -g npm + npm install -g typescript@latest + npm install -g @vscode/vsce + + vsce package + + Move-Item (Join-Path $RootDir "*.vsix") (Join-Path $RootDir "kit") } Pop-Location } -task Build BuildHost, BuildWinFormDesigner, BuildCmdlets, BuildExtension +task Build GenerateVSCodeApi, BuildHost, BuildWinFormDesigner, BuildCmdlets, BuildExtension task . Init, Clean, Build -Pop-Location \ No newline at end of file +Pop-Location