for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Bruli\EventBusBundle;
class BusOptionsResolver
{
/**
* @var array
*/
private $option = [];
private $preMiddleWareOption = [];
private $postMiddleWareOption = [];
* @param string $command
* @param string $handler
public function addOption($command, $handler)
$this->option[$command] = $handler;
}
public function addPreMiddleWareOption($command, $handler)
$this->preMiddleWareOption[$command] = $handler;
public function addPostMiddleWareOption($command, $handler)
*
* @return string
public function getOption($command)
return $this->option[$command];
public function getPreMiddleWareOption($command)
return $this->preMiddleWareOption[$command];
* @return bool
public function preMiddleWareHasCommand($command)
return array_key_exists($command, $this->preMiddleWareOption);
public function postMiddleWareHasCommand($command)
public function getPostMiddleWareOption($command)
return $this->postMiddleWareOption[$command];