save() публичный Метод

Saves a system cache.
public save ( string $type, string $data ) : boolean
$type string The type or identifier of the cache
$data string The data to be saved
Результат boolean
Пример #1
0
 /**
  * Cache the configuration
  *
  * @param SystemCache $cache The system cache
  * @return void
  * @access private
  */
 public function cacheConfiguration(SystemCache $cache)
 {
     $cache->save('view_locations', serialize(['version' => '2.0', 'locations' => $this->locations]));
     // this is saved just for the inspector and is not loaded in loadAll()
     $cache->save('view_overrides', serialize($this->overrides));
 }