public static function getTypeFromFileName(string $fileName): string
    {
        $fileExtension = strtolower(Miscellaneous::getFileExtension($fileName));

        // Oops, incorrect type/extension of configuration file
        if (false === (new static())->isCorrectType($fileExtension)) {
            throw UnknownConfigurationFileTypeException::createException($fileExtension);
        }

        return $fileExtension;
    }
public static function getTypeFromFileName(string $fileName): string
    {
        $fileExtension = strtolower(Miscellaneous::getFileExtension($fileName));

        // Oops, incorrect type/extension of configuration file
        if (false === (new static())->isCorrectType($fileExtension)) {
            throw UnknownConfigurationFileTypeException::createException($fileExtension);
        }

        return $fileExtension;
    }
public static function getTypeFromFileName ( string $ fileName ) : string { $ fileExtension = strtolower ( Miscellaneous :: getFileExtension ( $ fileName ) ) ; // Oops, incorrect type/extension of configuration file if ( false === ( new static ( ) ) -> isCorrectType ( $ fileExtension ) ) { throw UnknownConfigurationFileTypeException :: createException ( $ fileExtension ) ; } return $ fileExtension ; }
Returns type of configuration file based on name of the file

@param string $fileName Name of configuration file
@throws UnknownConfigurationFileTypeException
@return string
Returns type of configuration file based on name of the file