Files
night-shift/src/Features/Console/Contracts/CommandArgSpec.cs
T

12 lines
383 B
C#

using System.Collections.Generic;
namespace Game.Features.Console.Contracts;
public sealed record CommandArgSpec(string Name, CommandArgType Type, IReadOnlyList<string> Choices = null)
{
public override string ToString() =>
Type == CommandArgType.Choice && Choices is not null
? string.Join("|", Choices)
: Type.ToString().ToLowerInvariant();
}