izzum\statemachine\StateMachine::handlePossibleNonStatemachineException PHP Method

handlePossibleNonStatemachineException() protected method

Always throws an izzum exception (converts a non-izzum exception to an izzum exception)
protected handlePossibleNonStatemachineException ( Exception $e, integer $code, Transition $transition = null )
$e Exception
$code integer if the exception is not of type Exception, wrap it and use this code.
$transition Transition optional. if set, we handle it as a transition exception too so it can be logged or handled
    protected function handlePossibleNonStatemachineException(\Exception $e, $code, $transition = null)
    {
        $e = Utils::wrapToStateMachineException($e, $code);
        if ($transition !== null) {
            $this->handleTransitionException($transition, $e);
        }
        throw $e;
    }