1 write to IdentifierToken
System.CommandLine (1)
Parsing\OptionResult.cs (1)
22
IdentifierToken
= token;
31 references to IdentifierToken
dotnet (1)
Extensions\ParseResultExtensions.cs (1)
171
return optionResult.
IdentifierToken
?? new Token($"--{optionResult.Option.Name}", TokenType.Option, optionResult.Option);
dotnet-watch (1)
CommandLine\CommandLineOptions.cs (1)
329
=> optionResult.
IdentifierToken
?.Value ?? optionResult.Option.Name;
Microsoft.DotNet.Cli.Definitions (4)
Commands\New\CommandDefinitionExtensions.cs (3)
98
if (optionResult.
IdentifierToken
is { } && !string.IsNullOrWhiteSpace(optionResult.
IdentifierToken
.Value))
100
wrongTokens.Add($"'{optionResult.
IdentifierToken
.Value}'");
Help\LocalizationResources.cs (1)
109
private static string GetOptionName(OptionResult optionResult) => optionResult.
IdentifierToken
?.Value ?? optionResult.Option.Name;
Microsoft.TemplateEngine.Cli (19)
ChoiceTemplateParameter.cs (6)
117
or.
IdentifierToken
?.Value,
123
argumentResult.AddError(string.Format(LocalizableStrings.ParseTemplateOption_Error_MissingDefaultValue, or.
IdentifierToken
?.Value));
136
or.
IdentifierToken
?.Value,
142
argumentResult.AddError(string.Format(LocalizableStrings.ParseTemplateOption_Error_MissingDefaultIfNoOptionValue, or.
IdentifierToken
?.Value));
148
argumentResult.AddError(string.Format(LocalizableStrings.ParseTemplateOption_Error_InvalidCount, or.
IdentifierToken
?.Value, argumentResult.Tokens.Count));
159
or.
IdentifierToken
?.Value,
CliTemplateParameter.cs (6)
338
or.
IdentifierToken
?.Value,
346
argumentResult.AddError(string.Format(LocalizableStrings.ParseTemplateOption_Error_MissingDefaultValue, or.
IdentifierToken
?.Value));
360
or.
IdentifierToken
?.Value,
365
argumentResult.AddError(string.Format(LocalizableStrings.ParseTemplateOption_Error_MissingDefaultIfNoOptionValue, or.
IdentifierToken
?.Value));
379
or.
IdentifierToken
?.Value,
386
argumentResult.AddError(string.Format(LocalizableStrings.ParseTemplateOption_Error_InvalidCount, or.
IdentifierToken
?.Value, argumentResult.Tokens.Count));
Commands\BaseFilterableArgs.cs (1)
42
return _filters[filter].
IdentifierToken
?.Value;
Commands\create\InstantiateCommand.NoMatchHandling.cs (2)
192
if (result.GetResult(option) is { } optionResult && optionResult.
IdentifierToken
is { } token)
206
if (option.Condition && result.GetResult(option.Option) is { } optionResult && optionResult.
IdentifierToken
is { } token)
Commands\create\InstantiateCommandArgs.cs (1)
44
if (optionResult.
IdentifierToken
is { } token)
Commands\create\InvalidTemplateOptionResult.cs (1)
102
optionResult.
IdentifierToken
?.Value ?? string.Empty,
Commands\create\TemplateOptionResult.cs (1)
48
optionResult.
IdentifierToken
?.Value ?? string.Empty,
Commands\NewCommandArgs.cs (1)
39
if (o.
IdentifierToken
is { } token) { tokensToEvaluate.Add(token); }
System.CommandLine (6)
LocalizationResources.cs (1)
257
private static string GetOptionName(OptionResult optionResult) => optionResult.
IdentifierToken
?.Value ?? optionResult.Option.Name;
Parsing\OptionResult.cs (3)
34
public bool Implicit =>
IdentifierToken
is null ||
IdentifierToken
.Implicit;
48
public override string ToString() => $"{nameof(OptionResult)}: {
IdentifierToken
?.Value ?? Option.Name} {string.Join(" ", Tokens.Select(t => t.Value))}";
Parsing\ParseDiagramAction.cs (1)
142
builder.Append(optionResult.
IdentifierToken
?.Value ?? optionResult.Option.Name);
VersionOption.cs (1)
58
result.AddError(LocalizationResources.VersionOptionCannotBeCombinedWithOtherArguments(result.
IdentifierToken
?.Value ?? result.Option.Name));