@@ -22,6 +22,6 @@ |
||
22 | 22 | } |
23 | 23 | |
24 | 24 | return parent::setBody(['query' => "SHOW THREADS " . |
25 | - ((count($options)>0)?' OPTION '.implode(",", $options):'')]); |
|
25 | + ((count($options) > 0) ? ' OPTION ' . implode(",", $options) : '')]); |
|
26 | 26 | } |
27 | 27 | } |
@@ -19,7 +19,7 @@ |
||
19 | 19 | { |
20 | 20 | $this->body = $params; |
21 | 21 | if (isset($params['library'])) { |
22 | - return parent::setBody(['query' => "RELOAD PLUGINS FROM SONAME ".$params['library']]); |
|
22 | + return parent::setBody(['query' => "RELOAD PLUGINS FROM SONAME " . $params['library']]); |
|
23 | 23 | } |
24 | 24 | throw new RuntimeException('library name not present in /nodes/reloadplugins'); |
25 | 25 | } |
@@ -16,7 +16,7 @@ |
||
16 | 16 | public function setBody($params = null) |
17 | 17 | { |
18 | 18 | if (isset($params['name'])) { |
19 | - return parent::setBody(['query' => "DROP PLUGIN " . $params['name']." TYPE".$params['type']]); |
|
19 | + return parent::setBody(['query' => "DROP PLUGIN " . $params['name'] . " TYPE" . $params['type']]); |
|
20 | 20 | } |
21 | 21 | throw new RuntimeException('Missing plugin name in /nodes/dropplugin'); |
22 | 22 | } |
@@ -16,8 +16,8 @@ |
||
16 | 16 | public function setBody($params = null) |
17 | 17 | { |
18 | 18 | if (isset($params['name'], $params['type']) && $params['library']) { |
19 | - return parent::setBody(['query' => "CREATE PLUGIN " . $params['name']. |
|
20 | - " TYPE ".strtoupper($params['type']). " SONAME ".$params['library']]); |
|
19 | + return parent::setBody(['query' => "CREATE PLUGIN " . $params['name'] . |
|
20 | + " TYPE " . strtoupper($params['type']) . " SONAME " . $params['library']]); |
|
21 | 21 | } |
22 | 22 | |
23 | 23 | throw new RuntimeException('Incomplete request for /nodes/createplugin'); |
@@ -18,8 +18,8 @@ |
||
18 | 18 | $this->body = $params; |
19 | 19 | if (isset($params['variable']) && is_array($params['variable'])) { |
20 | 20 | return parent::setBody([ |
21 | - 'query' => "SET " . (isset($params['type']) ? $params['type'] . "'" : "")." ". |
|
22 | - $params['variable']['name']."=" . $params['variable']['value'] |
|
21 | + 'query' => "SET " . (isset($params['type']) ? $params['type'] . "'" : "") . " " . |
|
22 | + $params['variable']['name'] . "=" . $params['variable']['value'] |
|
23 | 23 | ]); |
24 | 24 | } |
25 | 25 | throw new RuntimeException('Variable is missing for /nodes/set'); |
@@ -18,8 +18,8 @@ |
||
18 | 18 | public function setBody($params = null) |
19 | 19 | { |
20 | 20 | if (isset($this->index)) { |
21 | - return parent::setBody(['query' => "DESCRIBE ".$this->index. " ". |
|
22 | - (isset($params['pattern'])?" LIKE '".$params['pattern']."'":"")]); |
|
21 | + return parent::setBody(['query' => "DESCRIBE " . $this->index . " " . |
|
22 | + (isset($params['pattern']) ? " LIKE '" . $params['pattern'] . "'" : "")]); |
|
23 | 23 | } |
24 | 24 | throw new RuntimeException('Index name is missing.'); |
25 | 25 | } |
@@ -22,8 +22,8 @@ |
||
22 | 22 | public function setBody($params = null) |
23 | 23 | { |
24 | 24 | if (isset($this->index)) { |
25 | - return parent::setBody(['query' => "OPTIMIZE INDEX ".$this->index. "". |
|
26 | - (isset($params['sync'])?" OPTION sync='".$params['sync']."'":"")]); |
|
25 | + return parent::setBody(['query' => "OPTIMIZE INDEX " . $this->index . "" . |
|
26 | + (isset($params['sync']) ? " OPTION sync='" . $params['sync'] . "'" : "")]); |
|
27 | 27 | } |
28 | 28 | throw new RuntimeException('Index name is missing.'); |
29 | 29 | } |
@@ -22,8 +22,8 @@ |
||
22 | 22 | public function setBody($params = null) |
23 | 23 | { |
24 | 24 | if (isset($this->index)) { |
25 | - return parent::setBody(['query' => "TRUNCATE RTINDEX ".$this->index. "". |
|
26 | - (isset($params['with'])?" WITH'".strtoupper($params['with'])."'":"")]); |
|
25 | + return parent::setBody(['query' => "TRUNCATE RTINDEX " . $this->index . "" . |
|
26 | + (isset($params['with']) ? " WITH'" . strtoupper($params['with']) . "'" : "")]); |
|
27 | 27 | } |
28 | 28 | throw new RuntimeException('Index name is missing.'); |
29 | 29 | } |
@@ -19,7 +19,7 @@ |
||
19 | 19 | { |
20 | 20 | |
21 | 21 | if (isset($this->index)) { |
22 | - return parent::setBody(['query' => "FLUSH RAMCHUNK ".$this->index]); |
|
22 | + return parent::setBody(['query' => "FLUSH RAMCHUNK " . $this->index]); |
|
23 | 23 | } |
24 | 24 | throw new RuntimeException('Index name is missing.'); |
25 | 25 | } |