PHP Class Stiphle\Storage\Memcached

Author: Dave Marshall ([email protected])
Inheritance: implements Stiphle\Storage\StorageInterface
Afficher le fichier Open project: davedevelopment/stiphle

Protected Properties

Свойство Type Description
$lockWaitTimeout integer
$memcached Memcached instance
$sleep Time to sleep when attempting to get lock in microseconds
$ttl integer

Méthodes publiques

Méthode Description
__construct ( Memcached $memcached ) Constructor
get ( string $key ) : integer Get last modified
lock ( $key ) : void Lock
set ( string $key, mixed $value ) : void set
setLockWaitTimeout ( integer $milliseconds ) Set lock wait timeout
setSleep ( $microseconds ) : void Set the sleep time in microseconds
setTtl ( $microseconds ) : void Set the ttl for the apc records in seconds
unlock ( $key ) : void Unlock

Method Details

__construct() public méthode

Constructor
public __construct ( Memcached $memcached )
$memcached Memcached

get() public méthode

Get last modified
public get ( string $key ) : integer
$key string
Résultat integer

lock() public méthode

If we're using storage, we might have multiple requests coming in at once, so we lock the storage
public lock ( $key ) : void
Résultat void

set() public méthode

set
public set ( string $key, mixed $value ) : void
$key string
$value mixed
Résultat void

setLockWaitTimeout() public méthode

Set lock wait timeout
public setLockWaitTimeout ( integer $milliseconds )
$milliseconds integer

setSleep() public méthode

Set the sleep time in microseconds
public setSleep ( $microseconds ) : void
Résultat void

setTtl() public méthode

Set the ttl for the apc records in seconds
public setTtl ( $microseconds ) : void
Résultat void

unlock() public méthode

Unlock
public unlock ( $key ) : void
Résultat void

Property Details

$lockWaitTimeout protected_oe property

protected int $lockWaitTimeout
Résultat integer

$memcached protected_oe property

Memcached instance
protected $memcached

$sleep protected_oe property

Time to sleep when attempting to get lock in microseconds
protected $sleep

$ttl protected_oe property

protected int $ttl
Résultat integer