| Total Complexity | 4 |
| Total Lines | 30 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 10 | class FlushRamchunk extends EmulateBySql |
||
| 11 | { |
||
| 12 | use Utils; |
||
| 13 | /** |
||
| 14 | * @var string |
||
| 15 | */ |
||
| 16 | protected $index; |
||
| 17 | |||
| 18 | public function setBody($params = null) |
||
| 19 | { |
||
| 20 | |||
| 21 | if (isset($this->index)) { |
||
| 22 | return parent::setBody(['query' => "FLUSH RAMCHUNK ".$this->index]); |
||
| 23 | } |
||
| 24 | throw new RuntimeException('Index name is missing.'); |
||
| 25 | } |
||
| 26 | /** |
||
| 27 | * @return mixed |
||
| 28 | */ |
||
| 29 | public function getIndex() |
||
| 32 | } |
||
| 33 | |||
| 34 | /** |
||
| 35 | * @param mixed $index |
||
| 36 | */ |
||
| 37 | public function setIndex($index) |
||
| 40 | } |
||
| 41 | } |
||
| 42 |