| File: AppModels\DefaultAppModel.cs | Web Access |
| Project: src\sdk\src\Dotnet.Watch\Watch\Microsoft.DotNet.HotReload.Watch.csproj (Microsoft.DotNet.HotReload.Watch) |
// Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. using Microsoft.Build.Graph; using Microsoft.DotNet.HotReload; using Microsoft.Extensions.Logging; namespace Microsoft.DotNet.Watch; /// <summary> /// Default model. /// </summary> internal sealed class DefaultAppModel(ProjectGraphNode project) : HotReloadAppModel { public override ValueTask<HotReloadClients> CreateClientsAsync(ILogger clientLogger, ILogger agentLogger, CancellationToken cancellationToken) => new(new HotReloadClients( clients: IsManagedAgentSupported(project, clientLogger) ? [new DefaultHotReloadClient(clientLogger, agentLogger, GetStartupHookPath(project), handlesStaticAssetUpdates: true, new NamedPipeClientTransport(clientLogger))] : [], browserRefreshServer: null, useRefreshServerToApplyStaticAssets: false)); }