Class

eZExpiryHandler

class eZExpiryHandler

Keeps track of expiry keys and their timestamps

Properties

array $Timestamps Holds the expiry timestamps array
bool $IsModified Wether data has been modified or not

Methods

__construct()

void restore()

Load the expiry timestamps from cache

store()

Stores the current timestamps values to cache

setTimestamp(string $name, int $value)

Sets the expiry timestamp for a key

bool hasTimestamp(string $name)

Checks if an expiry timestamp exist

int|false timestamp(string $name)

Returns the expiry timestamp for a key

static  registerShutdownFunction()

Registers the shutdown function.

Details

at line 17
public __construct()

at line 32
public void restore()

Load the expiry timestamps from cache

Return Value

void

at line 59
public store()

Stores the current timestamps values to cache

at line 92
public setTimestamp(string $name, int $value)

Sets the expiry timestamp for a key

Parameters

string $name Expiry key
int $value Expiry timestamp value

at line 105
public bool hasTimestamp(string $name)

Checks if an expiry timestamp exist

Parameters

string $name Expiry key name

Return Value

bool true if the timestamp exists, false otherwise

at line 117
public int|false timestamp(string $name)

Returns the expiry timestamp for a key

Parameters

string $name Expiry key

Return Value

int|false The timestamp if it exists, false otherwise

at line 187
static public registerShutdownFunction()

Registers the shutdown function.

See also

eZExpiryHandler::shutdown()