Key
class Key
Key is a container for the state of the locks in stores.
Methods
Details
__construct(string $resource)
Parameters
__toString()
bool hasState(string $stateKey)
Parameters
Return Value
void setState(string $stateKey, $state)
Parameters
Return Value
void removeState(string $stateKey)
Parameters
Return Value
getState(string $stateKey)
Parameters
resetLifetime()
reduceLifetime(float $ttl)
Parameters
float |
$ttl |
the expiration delay of locks in seconds |
float|null getRemainingLifetime()
Returns the remaining lifetime.
Return Value
float|null |
Remaining lifetime in seconds. Null when the key won't expire. |
bool isExpired()
Return Value