-
Notifications
You must be signed in to change notification settings - Fork 0
CI_Cache_memcached
CodeIgniter Memcached Caching Class
This class enables you to create drivers for a Library based on the Driver Library. It handles the drivers' access to the parent library
- Class name: CI_Cache_memcached
- Namespace:
- Parent class: CI_Driver
protected object $_memcached
Holds the memcached object
- Visibility: protected
protected array $_memcache_conf = array('default' => array('host' => '127.0.0.1', 'port' => 11211, 'weight' => 1))
Memcached configuration
- Visibility: protected
protected object $_parent
Instance of the parent class
- Visibility: protected
protected array $_methods = array()
List of methods in the parent class
- Visibility: protected
protected array $_properties = array()
List of properties in the parent class
- Visibility: protected
protected array $_reflections = array()
Array of methods and properties for the parent class(es)
- Visibility: protected
- This property is static.
void CI_Cache_memcached::__construct()
Class constructor
Setup Memcache(d)
- Visibility: public
mixed CI_Cache_memcached::get(string $id)
Fetch from cache
- Visibility: public
- $id string - <p>Cache ID</p>
boolean CI_Cache_memcached::save(string $id, mixed $data, integer $ttl, boolean $raw)
Save
- Visibility: public
- $id string - <p>Cache ID</p>
- $data mixed - <p>Data being cached</p>
- $ttl integer - <p>Time to live</p>
- $raw boolean - <p>Whether to store the raw value</p>
boolean CI_Cache_memcached::delete($id)
Delete from Cache
- Visibility: public
- $id mixed
mixed CI_Cache_memcached::increment(string $id, integer $offset)
Increment a raw value
- Visibility: public
- $id string - <p>Cache ID</p>
- $offset integer - <p>Step/value to add</p>
mixed CI_Cache_memcached::decrement(string $id, integer $offset)
Decrement a raw value
- Visibility: public
- $id string - <p>Cache ID</p>
- $offset integer - <p>Step/value to reduce by</p>
boolean CI_Cache_memcached::clean()
Clean the Cache
- Visibility: public
mixed CI_Cache_memcached::cache_info()
Cache Info
- Visibility: public
mixed CI_Cache_memcached::get_metadata($id)
Get Cache Metadata
- Visibility: public
- $id mixed
boolean CI_Cache_memcached::is_supported()
Is supported
Returns FALSE if memcached is not supported on the system. If it is, we setup the memcached object & return TRUE
- Visibility: public
void CI_Driver::decorate($parent)
Decorate
Decorates the child with the parent driver lib's methods and properties
- Visibility: public
- This method is defined by CI_Driver
- $parent mixed
mixed CI_Driver::__call($method, $args)
__call magic method
Handles access to the parent driver library's methods
- Visibility: public
- This method is defined by CI_Driver
- $method mixed
- $args mixed
mixed CI_Driver::__get($var)
__get magic method
Handles reading of the parent driver library's properties
- Visibility: public
- This method is defined by CI_Driver
- $var mixed
mixed CI_Driver::__set($var, $val)
__set magic method
Handles writing to the parent driver library's properties
- Visibility: public
- This method is defined by CI_Driver
- $var mixed
- $val mixed