Implemented draft for ActionManagement

This commit is contained in:
Kevin Frantz
2019-01-27 15:28:25 +01:00
parent f7242f725e
commit 707df1b951
46 changed files with 686 additions and 831 deletions

View File

@@ -0,0 +1,42 @@
<?php
namespace App\Domain\ActionManagement\Read;
use App\Domain\ActionManagement\AbstractAction;
/**
* @author kevinfrantz
*/
final class ReadAction extends AbstractAction implements ReadActionInterface
{
/**
* {@inheritdoc}
*
* @see \App\Domain\ActionManagement\AbstractAction::isSecure()
*/
protected function isSecure(): bool
{
return $this->actionService->isRequestedActionSecure();
}
/**
* @todo Implement!
* {@inheritdoc}
*
* @see \App\Domain\ActionManagement\AbstractAction::isValidByForm()
*/
protected function isValidByForm(): bool
{
return true;
}
/**
* {@inheritdoc}
*
* @see \App\Domain\ActionManagement\AbstractAction::proccess()
*/
protected function proccess()
{
return $this->actionService->getRequestedAction()->getRequestedEntity()->getEntity();
}
}

View File

@@ -0,0 +1,14 @@
<?php
namespace App\Domain\ActionManagement\Read;
use App\Domain\ActionManagement\ActionInterface;
/**
* Needed for mocking with PHPUnit!
*
* @author kevinfrantz
*/
interface ReadActionInterface extends ActionInterface
{
}