HandlebarsCacheAPC

A dummy array cache.

Defined (2)

The class is defined in the following location(s).

/vendor/calderawp/metaplate-core/vendor/xamin/handlebars.php/src/Handlebars/Cache/APC.php  
  1. class APC implements Cache 
  2.  
  3. /** 
  4. * Get cache for $name if exist. 
  5. * @param string $name Cache id 
  6. * @return mixed data on hit, boolean false on cache not found 
  7. */ 
  8. public function get($name) 
  9. if (apc_exists($name)) { 
  10. return apc_fetch($name); 
  11. return false; 
  12.  
  13. /** 
  14. * Set a cache 
  15. * @param string $name cache id 
  16. * @param mixed $value data to store 
  17. * @return void 
  18. */ 
  19. public function set($name, $value) 
  20. apc_store($name, $value); 
  21.  
  22. /** 
  23. * Remove cache 
  24. * @param string $name Cache id 
  25. * @return void 
  26. */ 
  27. public function remove($name) 
  28. apc_delete($name); 
  29.  
/vendor/xamin/handlebars.php/src/Handlebars/Cache/APC.php  
  1. class APC implements Cache 
  2.  
  3. /** 
  4. * Get cache for $name if exist. 
  5. * @param string $name Cache id 
  6. * @return mixed data on hit, boolean false on cache not found 
  7. */ 
  8. public function get($name) 
  9. if (apc_exists($name)) { 
  10. return apc_fetch($name); 
  11. return false; 
  12.  
  13. /** 
  14. * Set a cache 
  15. * @param string $name cache id 
  16. * @param mixed $value data to store 
  17. * @return void 
  18. */ 
  19. public function set($name, $value) 
  20. apc_store($name, $value); 
  21.  
  22. /** 
  23. * Remove cache 
  24. * @param string $name Cache id 
  25. * @return void 
  26. */ 
  27. public function remove($name) 
  28. apc_delete($name); 
  29.