12 lines
383 B
C#
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();
|
|
}
|