Example #1
0
 /**
  * @param string $sectionId
  * @return void
  */
 private function loadSection($sectionId)
 {
     if (!isset($this->cacheSections[$sectionId])) {
         $value = $this->cache->load($sectionId);
         if ($value) {
             $this->cacheSections[$sectionId] = json_decode($value, true);
         } else {
             $this->cacheSections[$sectionId] = [];
         }
     }
 }
Example #2
0
 /**
  * {@inheritdoc}
  */
 public function getFromCache($type, $file, $area, $themePath, $locale, $module)
 {
     $cacheId = $this->getCacheId($type, $file, $area, $themePath, $locale, $module);
     return $this->cache->load($cacheId);
 }