PHP Class Pop\Cache\Adapter\Memcached

Author: Nick Sagona, III ([email protected])
Inheritance: implements Pop\Cache\Adapter\AdapterInterface
Exibir arquivo Open project: nicksagona/PopPHP

Protected Properties

Property Type Description
$memcache Pop\Cache\Adapter\Memcache Memcache object
$version string Memcache version

Public Methods

Method Description
__construct ( string $host = 'localhost', integer $port = 11211 ) : Memcached Constructor
clear ( ) : void Method to clear all stored values from cache.
getVersion ( ) : string Method to get the current version of memcache.
load ( string $id, string $time ) : mixed Method to load a value from cache.
remove ( string $id ) : void Method to delete a value in cache.
save ( string $id, mixed $value, string $time ) : void Method to save a value to cache.

Method Details

__construct() public method

Instantiate the memcache cache object
public __construct ( string $host = 'localhost', integer $port = 11211 ) : Memcached
$host string
$port integer
return Memcached

clear() public method

Method to clear all stored values from cache.
public clear ( ) : void
return void

getVersion() public method

Method to get the current version of memcache.
public getVersion ( ) : string
return string

load() public method

Method to load a value from cache.
public load ( string $id, string $time ) : mixed
$id string
$time string
return mixed

remove() public method

Method to delete a value in cache.
public remove ( string $id ) : void
$id string
return void

save() public method

Method to save a value to cache.
public save ( string $id, mixed $value, string $time ) : void
$id string
$value mixed
$time string
return void

Property Details

$memcache protected_oe property

Memcache object
protected Memcache,Pop\Cache\Adapter $memcache
return Pop\Cache\Adapter\Memcache

$version protected_oe property

Memcache version
protected string $version
return string