mirror of
https://github.com/Tyrrrz/CliFx.git
synced 2025-10-25 15:19:17 +00:00
Refactor & improve argument conversion feature
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
using CliFx.Attributes;
|
||||
|
||||
namespace CliFx.Tests.Commands.Invalid
|
||||
{
|
||||
[Command]
|
||||
public class InvalidCustomConverterOptionCommand : SelfSerializeCommandBase
|
||||
{
|
||||
[CommandOption('f', Converter = typeof(Converter))]
|
||||
public string? Option { get; set; }
|
||||
|
||||
public class Converter
|
||||
{
|
||||
public object ConvertFrom(string value) => value;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user