public function get($id, $default = NULL)
 {
     // dont get values when caching is disabled
     if (Arr::get($this->_config, 'disabled', FALSE)) {
         return $default;
     }
     return parent::get($id, $default);
 }
Exemplo n.º 2
0
 public function _failed_request($host, $port)
 {
     return parent::_failed_request($host, $port);
 }
Exemplo n.º 3
0
 /**
  * Callback method for Memcache::failure_callback to use if any Memcache call
  * on a particular server fails. This method switches off that instance of the
  * server if the configuration setting `instant_death` is set to `TRUE`.
  *
  * @param   string   hostname
  * @param   integer  port
  * @return  void|boolean
  * @todo    Broken in 3.0.8
  */
 public function _failed_request($hostname, $port)
 {
     parent::_failed_request($hostname, $port);
 }
Exemplo n.º 4
0
 /**
  * (non-PHPdoc)
  * @see modules/cache/classes/kohana/cache/Kohana_Cache_Memcache#delete()
  */
 public function delete($id, $timeout = 0)
 {
     if ($this->_config['profiling'] === TRUE) {
         $benchmark = Profiler::start("Cache Items", $id);
     }
     $data = parent::delete($id, $timeout);
     if (isset($benchmark)) {
         if (!$data) {
             Profiler::delete($benchmark);
         } else {
             Profiler::stop($benchmark);
         }
     }
     return $data;
 }