| Total Complexity | 5 |
| Total Lines | 18 |
| Duplicated Lines | 0 % |
| Coverage | 61.53% |
| Changes | 0 | ||
| 1 | <?php |
||
| 7 | class QueryCache extends DbCache { |
||
| 8 | |||
| 9 | 8 | public function fetch($tableName, $condition) { |
|
| 10 | 8 | $key=$tableName . "." . $this->getKey($condition); |
|
| 11 | 8 | if ($this->cache->exists($key)) |
|
| 12 | 2 | return $this->cache->fetch($key); |
|
| 13 | 7 | return false; |
|
| 14 | } |
||
| 15 | |||
| 16 | 7 | public function store($tableName, $condition, $result) { |
|
| 17 | 7 | $this->cache->store($tableName . "." . $this->getKey($condition), "return " . UArray::asPhpArray($result, "array") . ";"); |
|
| 18 | 7 | } |
|
| 19 | |||
| 20 | public function delete($tableName, $condition){ |
||
| 25 | } |
||
| 26 | } |
||
| 27 |