spaceonfire/command-bus
最新稳定版本:2.5.2
Composer 安装命令:
composer require spaceonfire/command-bus
包简介
Simple and extendable command bus
README 文档
README
Simple and extendable command bus.
Install
Via Composer
$ composer require spaceonfire/command-bus
Usage
use spaceonfire\CommandBus\CommandBus; use spaceonfire\CommandBus\Mapping\MapByStaticList; class MyCommand { } class MyCommandHandler { public function handle(MyCommand $command) { // Do your job to handle a command } } $commandBus = new CommandBus(new MapByStaticList([ MyCommand::class => [MyCommandHandler::class, 'handle'], ])); $commandBus->handle(new MyCommand());
Change log
Please see CHANGELOG for more information on what has changed recently.
Contributing
Report issues and send Pull Requests in the main spaceonfire repository. Please see CONTRIBUTING and CODE_OF_CONDUCT for details.
Credits
License
The MIT License (MIT). Please see License File for more information.
统计信息
- 总下载量: 7.03k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 1
其他信息
- 授权协议: MIT
- 更新时间: 2020-04-01