/**
* Getter for configuration instance
*
- * @return $cfgInstance Configuration instance
+ * @return $configInstance Configuration instance
*/
public final function getConfigInstance () {
- $cfgInstance = Registry::getRegistry()->getInstance('config');
- return $cfgInstance;
+ $configInstance = Registry::getRegistry()->getInstance('config');
+ return $configInstance;
}
/**
}
// Get configuration instance
- $cfgInstance = FrameworkConfiguration::getInstance();
+ $configInstance = FrameworkConfiguration::getInstance();
// Set the base path
$tplInstance->setBasePath($basePath);
$tplInstance->setFileIoInstance($ioInstance);
// Set template extensions
- $tplInstance->setRawTemplateExtension($cfgInstance->readConfig('raw_template_extension'));
- $tplInstance->setCodeTemplateExtension($cfgInstance->readConfig('code_template_extension'));
+ $tplInstance->setRawTemplateExtension($configInstance->readConfig('raw_template_extension'));
+ $tplInstance->setCodeTemplateExtension($configInstance->readConfig('code_template_extension'));
// Absolute output path for compiled templates
- $tplInstance->setCompileOutputPath($cfgInstance->readConfig('base_path') . $cfgInstance->readConfig('compile_output_path'));
+ $tplInstance->setCompileOutputPath($configInstance->readConfig('base_path') . $configInstance->readConfig('compile_output_path'));
// Return the prepared instance
return $tplInstance;
}
// Get configuration instance
- $cfgInstance = FrameworkConfiguration::getInstance();
+ $configInstance = FrameworkConfiguration::getInstance();
// Set the base path
$tplInstance->setBasePath($basePath);
$tplInstance->setFileIoInstance($ioInstance);
// Set template extensions
- $tplInstance->setRawTemplateExtension($cfgInstance->readConfig('raw_template_extension'));
- $tplInstance->setCodeTemplateExtension($cfgInstance->readConfig('code_template_extension'));
+ $tplInstance->setRawTemplateExtension($configInstance->readConfig('raw_template_extension'));
+ $tplInstance->setCodeTemplateExtension($configInstance->readConfig('code_template_extension'));
// Absolute output path for compiled templates
- $tplInstance->setCompileOutputPath($cfgInstance->readConfig('base_path') . $cfgInstance->readConfig('compile_output_path'));
+ $tplInstance->setCompileOutputPath($configInstance->readConfig('base_path') . $configInstance->readConfig('compile_output_path'));
// Return the prepared instance
return $tplInstance;
}
// Get configuration instance
- $cfgInstance = FrameworkConfiguration::getInstance();
+ $configInstance = FrameworkConfiguration::getInstance();
// Set the base path
$tplInstance->setBasePath($basePath);
$tplInstance->setFileIoInstance($ioInstance);
// Set template extensions
- $tplInstance->setRawTemplateExtension($cfgInstance->readConfig('raw_template_extension'));
- $tplInstance->setCodeTemplateExtension($cfgInstance->readConfig('code_template_extension'));
+ $tplInstance->setRawTemplateExtension($configInstance->readConfig('raw_template_extension'));
+ $tplInstance->setCodeTemplateExtension($configInstance->readConfig('code_template_extension'));
// Absolute output path for compiled templates
- $tplInstance->setCompileOutputPath($cfgInstance->readConfig('base_path') . $cfgInstance->readConfig('compile_output_path'));
+ $tplInstance->setCompileOutputPath($configInstance->readConfig('base_path') . $configInstance->readConfig('compile_output_path'));
// Return the prepared instance
return $tplInstance;
/**
* The configuration instance itself
*/
- private static $cfgInstance = null;
+ private static $configInstance = null;
// Some constants for the configuration system
const EXCEPTION_CONFIG_ENTRY_IS_EMPTY = 0x130;
/**
* Getter for an instance of this class
*
- * @return $cfgInstance An instance of this class
+ * @return $configInstance An instance of this class
*/
public final static function getInstance () {
// is the instance there?
- if (is_null(self::$cfgInstance)) {
+ if (is_null(self::$configInstance)) {
// Create a config instance
- self::$cfgInstance = new FrameworkConfiguration();
+ self::$configInstance = new FrameworkConfiguration();
} // END - if
- return self::$cfgInstance;
+ return self::$configInstance;
}
/**
* 1.3
* - Constructor is now empty and factory method 'createClassLoader' is created
* - renamed loadClasses to scanClassPath
- * - Added initLoader(), $cfgInstance renamed to $configInstance
+ * - Added initLoader(), $configInstance renamed to $configInstance
* 1.2
* - ClassLoader rewritten to PHP SPL's own RecursiveIteratorIterator class
* 1.1
*/
private static $selfInstance = null;
- /**
- * Configuration array
- */
- private $cfg = array();
-
/**
* Array with all classes
*/
*/
protected function initLoader (FrameworkConfiguration $configInstance) {
// Set configuration instance
- $this->cfgInstance = $configInstance;
+ $this->configInstance = $configInstance;
// Construct the FQFN for the cache
if (!defined('DEVELOPER')) {
- $this->listCacheFQFN = $this->cfgInstance->readConfig('local_db_path') . "list-" . $this->cfgInstance->readConfig('app_name') . ".cache";
- $this->classCacheFQFN = $this->cfgInstance->readConfig('local_db_path') . "class-" . $this->cfgInstance->readConfig('app_name') . ".cache";
+ $this->listCacheFQFN = $this->configInstance->readConfig('local_db_path') . "list-" . $this->configInstance->readConfig('app_name') . ".cache";
+ $this->classCacheFQFN = $this->configInstance->readConfig('local_db_path') . "class-" . $this->configInstance->readConfig('app_name') . ".cache";
} // END - if
// Set suffix and prefix from configuration
$this->prefix = "config-";
// Set base directory
- $basePath = sprintf("%sinc/config/", $this->cfgInstance->readConfig('base_path'));
+ $basePath = sprintf("%sinc/config/", $this->configInstance->readConfig('base_path'));
// Load all classes from the config directory
$this->scanClassPath($basePath);