From dde4159eaf6f02168457e45bb5cfd9a8e55da5ea Mon Sep 17 00:00:00 2001 From: soroshsabz Date: Fri, 17 Feb 2023 19:17:15 +0330 Subject: [PATCH] Update language client. (see #4) --- .../AnsibleLanguageClient.cs | 43 ++++++++++++++++++- 1 file changed, 41 insertions(+), 2 deletions(-) diff --git a/Source/Ansible.VisualStudio/AnsibleLanguageClient.cs b/Source/Ansible.VisualStudio/AnsibleLanguageClient.cs index f51bba1..4999ca0 100644 --- a/Source/Ansible.VisualStudio/AnsibleLanguageClient.cs +++ b/Source/Ansible.VisualStudio/AnsibleLanguageClient.cs @@ -1,12 +1,51 @@ -using System; +using Microsoft.VisualStudio.LanguageServer.Client; +using Microsoft.VisualStudio.Threading; +using Microsoft.VisualStudio.Utilities; +using System; using System.Collections.Generic; +using System.ComponentModel.Composition; using System.Linq; using System.Text; +using System.Threading; using System.Threading.Tasks; namespace Ansible.VisualStudio { - public class AnsibleLanguageClient + [ContentType("ansible")] + [Export(typeof(ILanguageClient))] + public class AnsibleLanguageClient : ILanguageClient { + public string Name => "Ansible Language Extension"; + + public IEnumerable ConfigurationSections => null; + + public object InitializationOptions => null; + + public IEnumerable FilesToWatch => null; + + public bool ShowNotificationOnInitializeFailed => true; + + public event AsyncEventHandler StartAsync; + public event AsyncEventHandler StopAsync; + + public Task ActivateAsync(CancellationToken token) + { + throw new NotImplementedException(); + } + + public Task OnLoadedAsync() + { + throw new NotImplementedException(); + } + + public Task OnServerInitializedAsync() + { + throw new NotImplementedException(); + } + + public Task OnServerInitializeFailedAsync(ILanguageClientInitializationInfo initializationState) + { + throw new NotImplementedException(); + } } }