2 writes to ToolContext
dotnet-svcutil-lib (2)
Bootstrapper\SvcutilBootstrapper.cs (1)
39
this.Options.
ToolContext
= OperationalContext.Bootstrapper;
CommandProcessorOptions.cs (1)
261
this.
ToolContext
= CommandSwitch.DefaultSwitchLevel;
21 references to ToolContext
dotnet-svcutil-lib (21)
Bootstrapper\SvcutilBootstrapper.cs (4)
37
if (this.Options.
ToolContext
.HasValue && this.Options.
ToolContext
.Value <= OperationalContext.Global)
55
if (this.Options.
ToolContext
== OperationalContext.Infrastructure)
118
if (Options.
ToolContext
== OperationalContext.Infrastructure)
CommandProcessorOptions.cs (12)
259
if (!this.
ToolContext
.HasValue)
290
await safeLogger.WriteMessageAsync($"Tool context: {this.
ToolContext
}", logToUI: false).ConfigureAwait(false);
292
var disallowedContextSwitches = CommandSwitch.All.Where(s => s != Switches.ToolContext && s.SwitchLevel > this.
ToolContext
&& userOptions.Any(o => o.HasSameId(s.Name)));
321
Debug.Assert(this.
ToolContext
.HasValue, $"{nameof(
ToolContext
)} is not initialized!");
344
if (this.
ToolContext
== OperationalContext.Project)
352
if (this.
ToolContext
!= OperationalContext.Project)
438
if (!IsUpdateOperation && this.
ToolContext
<= OperationalContext.Global && File.Exists(filePath))
450
if (this.
ToolContext
== OperationalContext.Project && this.Project != null &&
471
if (this.
ToolContext
== OperationalContext.Project)
618
await logger.WriteMessageAsync(Shared.Resources.ResolvingProjectReferences, logToUI: this.
ToolContext
<= OperationalContext.Global).ConfigureAwait(false);
833
if (this.
ToolContext
== OperationalContext.Infrastructure)
Tool.cs (4)
175
if (options?.
ToolContext
<= OperationalContext.Global)
209
if (options.
ToolContext
!= OperationalContext.Infrastructure)
252
ToolConsole.WriteLineIf(options.
ToolContext
!= OperationalContext.Infrastructure, filePath, LogTag.Important);
400
if (options == null || options.
ToolContext
<= OperationalContext.Global)
ToolConsole.cs (1)
35
ToolModeLevel = options.
ToolContext
.Value;