| Conditions | 2 |
| Paths | 2 |
| Total Lines | 15 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 43 | protected function getPrefix() |
||
| 44 | { |
||
| 45 | /* |
||
| 46 | * It's easy enough to just set a prefix to be used, but we can not |
||
| 47 | * flush only a prefix! |
||
| 48 | * Instead, we'll generate a unique prefix key, based on some name. |
||
| 49 | * If we want to flush, we just create a new prefix and use that one. |
||
| 50 | */ |
||
| 51 | $index = $this->cache->get($this->collection); |
||
| 52 | |||
| 53 | if (false === $index) { |
||
| 54 | $index = $this->cache->set($this->collection, 1); |
||
| 55 | } |
||
| 56 | |||
| 57 | return $this->collection.':'.$index.':'; |
||
| 58 | } |
||
| 60 |