private function getStageInstance(string $stageClass): StageInterface
    {
        if (!class_exists($stageClass)) {
            throw new RuntimeException('Error: Could not find requested stage class.');
        }
        if (in_array("Zikula\\Component\\Wizard\\InjectContainerInterface", class_implements($stageClass), true)) {
            return new $stageClass($this->container);
        }

        return new $stageClass();
    }
private function getStageInstance(string $stageClass): StageInterface
    {
        if (!class_exists($stageClass)) {
            throw new RuntimeException('Error: Could not find requested stage class.');
        }
        if (in_array("Zikula\\Component\\Wizard\\InjectContainerInterface", class_implements($stageClass), true)) {
            return new $stageClass($this->container);
        }

        return new $stageClass();
    }
private function getStageInstance ( string $ stageClass ) : StageInterface { if ( ! class_exists ( $ stageClass ) ) { throw new RuntimeException ( 'Error: Could not find requested stage class.' ) ; } if ( in_array ( "Zikula\\Component\\Wizard\\InjectContainerInterface" , class_implements ( $ stageClass ) , true ) ) { return new $ stageClass ( $ this -> container ) ; } return new $ stageClass ( ) ; }
Factory class to instantiate a StageClass
Factory class to instantiate a StageClass