using GFramework.Core.Command;
namespace GFramework.Core.Tests.Command;
///
/// 表示 使用的同步测试命令。
///
public sealed class TestCommand : AbstractCommand
{
///
/// 初始化 的新实例。
///
/// 命令输入。
public TestCommand(TestCommandInput input) : base(input)
{
}
///
/// 获取一个值,该值指示命令是否已经执行。
///
public bool Executed { get; private set; }
///
/// 获取命令记录的执行结果值。
///
public int ExecutedValue { get; private set; }
///
/// 执行测试命令并记录同步执行状态。
///
/// 命令输入。
protected override void OnExecute(TestCommandInput input)
{
Executed = true;
ExecutedValue = 42;
}
}