public function cacheGet($name) {
    /* Do cache garbage collection. */
    $this->cacheGc();

    try {
      $data = $this->store->read('cache', $this->cacheId($name));
    } catch (\phpSec\Exception $e) {
      return false;
    }
    if($data ==! false) {
      if($data['ttl'] > time()) {
        return unserialize($data['data']);
      }
      $this->store->delete('cache', $this->cacheId($name));
    }
    return false;
  }
public function cacheGet($name) {
    /* Do cache garbage collection. */
    $this->cacheGc();

    try {
      $data = $this->store->read('cache', $this->cacheId($name));
    } catch (\phpSec\Exception $e) {
      return false;
    }
    if($data ==! false) {
      if($data['ttl'] > time()) {
        return unserialize($data['data']);
      }
      $this->store->delete('cache', $this->cacheId($name));
    }
    return false;
  }
public function cacheGet ( $ name ) { /* Do cache garbage collection. */ $ this -> cacheGc ( ) ; try { $ data = $ this -> store -> read ( 'cache' , $ this -> cacheId ( $ name ) ) ; } catch ( \ phpSec \ Exception $ e ) { return false ; } if ( $ data == ! false ) { if ( $ data [ 'ttl' ] > time ( ) ) { return unserialize ( $ data [ 'data' ] ) ; } $ this -> store -> delete ( 'cache' , $ this -> cacheId ( $ name ) ) ; } return false ; }
Get data from the cache.

@param string $name
String containing the name of the data to get.

@return mixed
Returns data in it's original form, or false if no data stored.
Get data from the cache .