$stateMachine =
$this->
getStateMachine($stateMachineName,
$context);
$stateMachineTransitions =
$stateMachine->
getTransitions();
if ($stateMachineTransitions === null
) { return [];
} $transitions =
[];
foreach ($stateMachineTransitions as $transition) { /** @var StateMachineStateEntity $fromState */
$fromState =
$transition->
getFromStateMachineState();
if ($fromState->
getId() ===
$fromStateId) { $transitions[] =
$transition;
} } return $transitions;
} /**
* @throws StateMachineException
* @throws IllegalTransitionException
* @throws UnnecessaryTransitionException
* @throws InconsistentCriteriaIdsException
*/