예제 #1
0
 /**
  * Returns the record for the current key. If there is no record than an empty array is returned.
  *
  * @return array
  */
 protected function getRecord()
 {
     $record = $this->driver->getData($this->key);
     if (!is_array($record)) {
         return array();
     }
     return $record;
 }
예제 #2
0
 /**
  * {@inheritdoc}
  */
 public function fetch($key)
 {
     $key = $this->createKeyArray($key);
     $data = $this->cache->getData($key);
     return isset($data['data']) ? $data['data'] : null;
 }