| Total Complexity | 7 |
| Total Lines | 62 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 2 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 10 | class Reviews extends ArrayObject |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var array |
||
| 14 | */ |
||
| 15 | public $args; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @var int |
||
| 19 | */ |
||
| 20 | public $max_num_pages; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @var array |
||
| 24 | */ |
||
| 25 | public $reviews; |
||
| 26 | |||
| 27 | public function __construct(array $reviews, $maxPageCount, array $args) |
||
| 33 | } |
||
| 34 | |||
| 35 | /** |
||
| 36 | * @return string |
||
| 37 | */ |
||
| 38 | public function __toString() |
||
| 39 | { |
||
| 40 | return (string) $this->build(); |
||
| 41 | } |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @return ReviewsHtml |
||
| 45 | */ |
||
| 46 | public function build() |
||
| 50 | } |
||
| 51 | |||
| 52 | /** |
||
| 53 | * @param mixed $key |
||
| 54 | * @return mixed |
||
| 55 | */ |
||
| 56 | public function offsetGet($key) |
||
| 57 | { |
||
| 58 | if (property_exists($this, $key)) { |
||
| 59 | return $this->$key; |
||
| 60 | } |
||
| 61 | return array_key_exists($key, $this->reviews) |
||
| 62 | ? $this->reviews[$key] |
||
| 63 | : null; |
||
| 64 | } |
||
| 65 | |||
| 66 | /** |
||
| 67 | * @return void |
||
| 68 | */ |
||
| 69 | public function render() |
||
| 72 | } |
||
| 73 | } |
||
| 74 |