|
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
using System.ComponentModel.Composition;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.ExternalAccess.Razor.Cohost;
using Microsoft.CodeAnalysis.Razor.Workspaces;
namespace Microsoft.VisualStudio.Razor.LanguageClient.Cohost;
[Export(typeof(IRazorCohostStartupService))]
[method: ImportingConstructor]
internal sealed class CohostActivator(ILspServerActivationTracker activationTracker) : IRazorCohostStartupService
{
private readonly ILspServerActivationTracker _activationTracker = activationTracker;
public int Order => WellKnownStartupOrder.Default;
public Task StartupAsync(VSInternalClientCapabilities clientCapabilities, RazorCohostRequestContext requestContext, CancellationToken cancellationToken)
{
_activationTracker.Activated();
return Task.CompletedTask;
}
}
|