-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
automatix
committed
Apr 24, 2018
1 parent
7705bb6
commit 5432341
Showing
5 changed files
with
25 additions
and
24 deletions.
There are no files selected for viewing
Empty file.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?php | ||
namespace App\Process\Listeners; | ||
|
||
use App\Base\Enums\Processes\EventNames\AbstractEventName; | ||
use App\Base\Enums\Processes\States\AbstractProcessState; | ||
use App\Process\StateHandlerInterface; | ||
use App\Services\Process\Internal\StateHandlers\Quest\AccessFailedHandler; | ||
use Symfony\Component\EventDispatcher\Event; | ||
use Symfony\Component\EventDispatcher\EventDispatcherInterface; | ||
|
||
class PoiListener extends AbstractProcessListener | ||
{ | ||
|
||
const RELEVANT_STATE_HANDLER_NAMESPACE = '\App\Services\Process\Internal\StateHandlers\Poi'; | ||
|
||
public function handle(Event $event, AbstractEventName $eventName, EventDispatcherInterface $eventDispatcher) | ||
{ | ||
$currentPoiState = $this->getStateManagingService()->detectPoiState(); | ||
$concreteHandler = $this->buildConcreteHandler($currentPoiState, $eventName); | ||
call_user_func($concreteHandler, $event, $eventName, $eventDispatcher); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters