public async Task InvokeAsync(ConsoleRequestContext context, RequestDelegate next) { CommandSeed commandSeed = commandPool.GetMatchingCommand(context.Arguments); ICommandModel commandModel = commandSeed.CreateModel(commandModelFactory); object commandView = commandSeed.CreateView(commandViewFactory); bool isLongCommandView = IsLongCommandView(commandView); if (isLongCommandView) { await ExecuteLongCommand(commandModel, commandView, context); } else { await ExecuteCommand(commandModel, commandView, context); } if (next != null) { await next.Invoke(context); } }
public FakeDeleteCommandBuilder(IFixture fixture, CommandSeed <FakeDeleteCommand> seed) : base(fixture, seed) { }
public FakeDispatcherCommandBuilder(IFixture fixture, CommandSeed <FakeDispatcherCommand> seed) : base(fixture, seed) { }
public FakeDeleteCommand FakeDeleteCommand(CommandSeed <FakeDeleteCommand> seed) { return(Fixtures.CommandFromBuilder(f => new FakeDeleteCommandBuilder(f, seed))); }