21 references to GetValueOrDefault
aspire (1)
Commands\RootCommand.cs (1)
156
var waitForDebugger = result.
GetValueOrDefault
<bool>();
crossgen2 (1)
src\runtime\src\coreclr\tools\Common\CommandLineHelpers.cs (1)
223
object val = optionResult.
GetValueOrDefault
<object>();
dotnet (4)
Commands\New\NewCommandParser.cs (1)
62
VerbosityOptions userSetVerbosity = verbosityOptionResult.
GetValueOrDefault
<VerbosityOptions>();
Commands\Pack\PackCommand.cs (1)
117
var globalProperties = parseResult.GetResult("--property") is OptionResult propResult ? propResult.
GetValueOrDefault
<ReadOnlyDictionary<string, string>?>() : null;
Commands\Tool\Install\ToolInstallGlobalOrToolPathCommand.cs (1)
134
result.
GetValueOrDefault
<T>() is { } t)
Telemetry\TopLevelCommandNameAndOptionToLog.cs (1)
26
&& optionResult.
GetValueOrDefault
<object>() is object optionValue
ilc (1)
src\runtime\src\coreclr\tools\Common\CommandLineHelpers.cs (1)
223
object val = optionResult.
GetValueOrDefault
<object>();
Microsoft.DotNet.Cli.CommandLine (2)
ForwardedOptionExtensions.cs (2)
43
if (r.
GetValueOrDefault
<TValue>() is TValue value)
66
if (r.
GetValueOrDefault
<TValue>() is TValue value)
Microsoft.DotNet.Cli.Definitions (1)
Commands\Workload\WorkloadSearchVersionsCommandDefinition.cs (1)
38
if (optionResult.
GetValueOrDefault
<int>() <= 0)
Microsoft.TemplateEngine.Cli (7)
Commands\BaseFilterableArgs.cs (1)
32
return _filters[filter].
GetValueOrDefault
<string>() ?? string.Empty;
Commands\create\InstantiateCommand.NoMatchHandling.cs (2)
162
example = example.WithOption(_ => language.Option, language.
GetValueOrDefault
<string>());
194
baseInputParameters += $", {token.Value}='{optionResult.
GetValueOrDefault
<string>()}'";
Commands\create\TemplateCommand.cs (1)
78
var value = optionResult.
GetValueOrDefault
<string>();
Commands\create\TemplateCommandArgs.cs (1)
108
var optionValue = optionResult.
GetValueOrDefault
<object>();
Commands\create\TemplateOptionResult.cs (1)
49
optionResult.Errors.Any() ? null : optionResult.
GetValueOrDefault
<object>()?.ToString());
Commands\Extensions.cs (1)
22
return result.
GetValueOrDefault
<object>()?.ToString();
System.CommandLine (4)
Parsing\SymbolResult.cs (4)
120
result.
GetValueOrDefault
<T>() is { } t)
140
OptionResult optionResult => optionResult.
GetValueOrDefault
<T>(),
154
optionResult.
GetValueOrDefault
<T>() is { } optionValue)
177
OptionResult optionResult => optionResult.
GetValueOrDefault
<T>(),