| @@ 28-60 (lines=33) @@ | ||
| 25 | * @package Elastification\Client\Response\V090x\Index |
|
| 26 | * @author Daniel Wendlandt |
|
| 27 | */ |
|
| 28 | class IndexResponse extends Response |
|
| 29 | { |
|
| 30 | ||
| 31 | const PROP_OK = 'ok'; |
|
| 32 | const PROP_ACKNOWLEDGED = 'acknowledged'; |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Getter Method |
|
| 36 | * |
|
| 37 | * @return mixed |
|
| 38 | * @author Daniel Wendlandt |
|
| 39 | */ |
|
| 40 | public function isOk() |
|
| 41 | { |
|
| 42 | $this->processData(); |
|
| 43 | ||
| 44 | return $this->get(self::PROP_OK); |
|
| 45 | } |
|
| 46 | ||
| 47 | /** |
|
| 48 | * Getter Method |
|
| 49 | * |
|
| 50 | * @return mixed |
|
| 51 | * @author Daniel Wendlandt |
|
| 52 | */ |
|
| 53 | public function acknowledged() |
|
| 54 | { |
|
| 55 | $this->processData(); |
|
| 56 | ||
| 57 | return $this->get(self::PROP_ACKNOWLEDGED); |
|
| 58 | } |
|
| 59 | ||
| 60 | } |
|
| 61 | ||
| @@ 28-60 (lines=33) @@ | ||
| 25 | * @package Elastification\Client\Response\V090x\Index |
|
| 26 | * @author Daniel Wendlandt |
|
| 27 | */ |
|
| 28 | class RefreshIndexResponse extends Response |
|
| 29 | { |
|
| 30 | ||
| 31 | const PROP_OK = 'ok'; |
|
| 32 | const PROP_SHARDS = '_shards'; |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Getter Method |
|
| 36 | * |
|
| 37 | * @return mixed |
|
| 38 | * @author Daniel Wendlandt |
|
| 39 | */ |
|
| 40 | public function isOk() |
|
| 41 | { |
|
| 42 | $this->processData(); |
|
| 43 | ||
| 44 | return $this->get(self::PROP_OK); |
|
| 45 | } |
|
| 46 | ||
| 47 | /** |
|
| 48 | * Getter Method |
|
| 49 | * |
|
| 50 | * @return mixed |
|
| 51 | * @author Daniel Wendlandt |
|
| 52 | */ |
|
| 53 | public function getShards() |
|
| 54 | { |
|
| 55 | $this->processData(); |
|
| 56 | ||
| 57 | return $this->get(self::PROP_SHARDS); |
|
| 58 | } |
|
| 59 | ||
| 60 | } |
|
| 61 | ||
| @@ 28-60 (lines=33) @@ | ||
| 25 | * @package Elastification\Client\Response\V2x\Index |
|
| 26 | * @author Daniel Wendlandt |
|
| 27 | */ |
|
| 28 | class CountResponse extends Response |
|
| 29 | { |
|
| 30 | ||
| 31 | const PROP_COUNT = 'count'; |
|
| 32 | const PROP_SHARDS = '_shards'; |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Getter Method |
|
| 36 | * |
|
| 37 | * @return mixed |
|
| 38 | * @author Daniel Wendlandt |
|
| 39 | */ |
|
| 40 | public function getCount() |
|
| 41 | { |
|
| 42 | $this->processData(); |
|
| 43 | ||
| 44 | return $this->get(self::PROP_COUNT); |
|
| 45 | } |
|
| 46 | ||
| 47 | /** |
|
| 48 | * Getter Method |
|
| 49 | * |
|
| 50 | * @return mixed |
|
| 51 | * @author Daniel Wendlandt |
|
| 52 | */ |
|
| 53 | public function getShards() |
|
| 54 | { |
|
| 55 | $this->processData(); |
|
| 56 | ||
| 57 | return $this->get(self::PROP_SHARDS); |
|
| 58 | } |
|
| 59 | ||
| 60 | } |
|
| 61 | ||