src/Infrastructure/CommonBundle/Subscriber/AbstractBusSitemapSubscriber.php line 25

Open in your IDE?
  1. <?php
  2. namespace Whater\Infrastructure\CommonBundle\Subscriber;
  3. use League\Tactician\CommandBus;
  4. use Symfony\Component\EventDispatcher\EventSubscriberInterface;
  5. abstract class AbstractBusSitemapSubscriber implements EventSubscriberInterface
  6. {
  7. /**
  8. * @var CommandBus
  9. */
  10. private $bus;
  11. public function setCommandBus(CommandBus $bus)
  12. {
  13. $this->bus = $bus;
  14. }
  15. /**
  16. * @param object $commandRequest
  17. * @return mixed
  18. */
  19. public function handle($commandRequest)
  20. {
  21. return $this->bus->handle($commandRequest);
  22. }
  23. }