Newscoop\Service\Resource\ResourceRepository::processConfigurationsPath PHP 메소드

processConfigurationsPath() 보호된 메소드

Provides the configuration path, where all property files are located.
protected processConfigurationsPath ( string $className ) : string
$className string The class name for which to locate the property file, this done by convention the class name can contain alaso the namespace which will be removed, the property file will be considered as the simple class name with the 'properties' extension.
리턴 string The config path based on the properties convention for the provided class name.
    protected function processConfigurationsPath($className)
    {
        Validation::notEmpty($className, 'className');
        $propertiesFolder = __DIR__;
        //Removing the 'Resources' from the dir path strlen('Resources')=9
        $propertiesFolder = substr($propertiesFolder, 0, -9);
        $simpleClassName = $this->extractSimpleClassName($className);
        return $propertiesFolder . '/configs/' . $simpleClassName . '.properties';
    }