src/Service/cacheService.php
public function init($objName = "", $lifeTime = 0)
    {
        if (strtoupper($this->cache) == "ENABLED") {
            if (strtoupper($this->cacheEngine) == "FILE" && $objName != "") {
                $objfolder = str_replace(".", "/", $objName) . "/";
                $objfolder = str_replace(array(':', ' '), '_', $objfolder);
                if (!strpos($this->cacheEngineOptions['cache_dir'], $objfolder)) {
                    $this->cacheEngineOptions['cache_dir'].=$objfolder;
                }
            }

            if (!file_exists($this->cacheEngineOptions['cache_dir'])) {
                $this->_makeDirectory($this->cacheEngineOptions['cache_dir'], 0777);
            }

            $this->cacheOptions['automatic_serialization'] = true;

            if ((int) $lifeTime > 0) {
                $this->cacheOptions['lifetime'] = (int) $lifeTime;
            }
            
            //require_once 'Zend/Cache.php';
            $this->cacheObj = \Zend_Cache::factory(
                            'Core', $this->cacheEngine, $this->cacheOptions, $this->cacheEngineOptions
            );
            return $this->cacheObj;
        } else {
            return false;
        }
    }
public function init($objName = "", $lifeTime = 0)
    {
        if (strtoupper($this->cache) == "ENABLED") {
            if (strtoupper($this->cacheEngine) == "FILE" && $objName != "") {
                $objfolder = str_replace(".", "/", $objName) . "/";
                $objfolder = str_replace(array(':', ' '), '_', $objfolder);
                if (!strpos($this->cacheEngineOptions['cache_dir'], $objfolder)) {
                    $this->cacheEngineOptions['cache_dir'].=$objfolder;
                }
            }

            if (!file_exists($this->cacheEngineOptions['cache_dir'])) {
                $this->_makeDirectory($this->cacheEngineOptions['cache_dir'], 0777);
            }

            $this->cacheOptions['automatic_serialization'] = true;

            if ((int) $lifeTime > 0) {
                $this->cacheOptions['lifetime'] = (int) $lifeTime;
            }
            
            //require_once 'Zend/Cache.php';
            $this->cacheObj = \Zend_Cache::factory(
                            'Core', $this->cacheEngine, $this->cacheOptions, $this->cacheEngineOptions
            );
            return $this->cacheObj;
        } else {
            return false;
        }
    }
Initialize cache

@param string $objName
@param number $lifeTime
@return boolean|\Zend_Cache