Пример #1
0
 /**
  * Save cache
  */
 public function __destruct()
 {
     foreach ($this->isDirty as $sectionId) {
         $value = json_encode($this->cacheSections[$sectionId]);
         $this->cache->save($value, $sectionId);
     }
 }
Пример #2
0
 /**
  * {@inheritdoc}
  */
 public function saveToCache($value, $type, $file, $area, $themePath, $locale, $module)
 {
     $cacheId = $this->getCacheId($type, $file, $area, $themePath, $locale, $module);
     return $this->cache->save($value, $cacheId);
 }