public function hasAllowableAction(Action $action)
    {
        $currentAllowableActions = $this->getAllowableActions();
        if ($currentAllowableActions === null || count($currentAllowableActions->getAllowableActions()) === 0) {
            throw new IllegalStateException('Allowable Actions are not available!');
        }

        return in_array($action, $currentAllowableActions->getAllowableActions(), false);
    }