protected function resolveHandler($solverOrName)
    {
        if (!is_string($solverOrName))
        {
            return $solverOrName;
        }

        $ex = null;
        $handler = null;

        try
        {
            $handler = $this->factory->create($solverOrName);
        }
        catch (Error $ex)
        {}
        catch (Exception $ex)
        {}

        if ($ex !== null)
        {
            throw new IllegalCallException("Tried to invoke [$solverOrName] which is undefined.");
        }

        return $handler;
    }