public function getValue($key)
{
$k = $this->hash($key);
if (!isset($this->cache[$k])) {
return null;
}
$item = $this->cache[$k];
if (isset($item->expire)) {
if (microtime(true) >= $item->expire) {
unset($this->cache[$k]);
return null;
}
}
return $item->getValue();
}