1 | <?php |
||
32 | class RepositoryBasedTransitionHandler extends AbstractTransitionHandler |
||
33 | { |
||
34 | /** |
||
35 | * The entity repository. |
||
36 | * |
||
37 | * @var EntityRepository |
||
38 | */ |
||
39 | private $entityRepository; |
||
40 | |||
41 | /** |
||
42 | * The state repository. |
||
43 | * |
||
44 | * @var StateRepository |
||
45 | */ |
||
46 | private $stateRepository; |
||
47 | |||
48 | /** |
||
49 | * Construct. |
||
50 | * |
||
51 | * @param Item $item The item. |
||
52 | * @param Workflow $workflow The current workflow. |
||
53 | * @param string|null $transitionName The transition to be handled. |
||
54 | * @param EntityRepository $entityRepository EntityRepository which stores changes. |
||
55 | * @param StateRepository $stateRepository StateRepository which stores new states. |
||
56 | * @param TransactionHandler $transactionHandler TransactionHandler take care of transactions. |
||
57 | * |
||
58 | * @throws WorkflowException If invalid transition name is given. |
||
59 | */ |
||
60 | public function __construct( |
||
73 | |||
74 | /** |
||
75 | * {@inheritdoc} |
||
76 | * |
||
77 | * @throws \Exception If something went wrong during action execution. |
||
78 | */ |
||
79 | public function transit(): State |
||
100 | } |
||
101 |