private function getStageClassName(string $name): string
    {
        if (!empty($this->stagesByName[$name])) {
            return $this->stagesByName[$name];
        }
        if (!empty($this->defaultStage) && !empty($this->stagesByName[$this->defaultStage])) {
            return $this->stagesByName[$this->defaultStage];
        }
        throw new InvalidArgumentException('The request stage could not be found and there is no default stage defined.');
    }
private function getStageClassName(string $name): string
    {
        if (!empty($this->stagesByName[$name])) {
            return $this->stagesByName[$name];
        }
        if (!empty($this->defaultStage) && !empty($this->stagesByName[$this->defaultStage])) {
            return $this->stagesByName[$this->defaultStage];
        }
        throw new InvalidArgumentException('The request stage could not be found and there is no default stage defined.');
    }
private function getStageClassName ( string $ name ) : string { if ( ! empty ( $ this -> stagesByName [ $ name ] ) ) { return $ this -> stagesByName [ $ name ] ; } if ( ! empty ( $ this -> defaultStage ) && ! empty ( $ this -> stagesByName [ $ this -> defaultStage ] ) ) { return $ this -> stagesByName [ $ this -> defaultStage ] ; } throw new InvalidArgumentException ( 'The request stage could not be found and there is no default stage defined.' ) ; }
Match the stage and return the stage classname or default.

@throws InvalidArgumentException
Match the stage and return the stage classname or default .