PHP Class Stiphle\Storage\Process

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

Protected Properties

Property Type Description
$lockWaitTimeout integer
$locked array
$values array

Public Methods

Method Description
get ( string $key ) : integer Get
lock ( $key ) : void Lock
set ( string $key, mixed $value ) : void set
setLockWaitTimeout ( integer $milliseconds ) Set lock wait timeout
unlock ( $key ) : void Unlock

Method Details

get() public method

Get
public get ( string $key ) : integer
$key string
return integer

lock() public method

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

set() public method

set
public set ( string $key, mixed $value ) : void
$key string
$value mixed
return void

setLockWaitTimeout() public method

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

unlock() public method

Unlock
public unlock ( $key ) : void
return void

Property Details

$lockWaitTimeout protected property

protected int $lockWaitTimeout
return integer

$locked protected property

protected array $locked
return array

$values protected property

protected array $values
return array