| Total Complexity | 11 |
| Total Lines | 137 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 12 | class FindResponse |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var Lawyer[] |
||
| 16 | */ |
||
| 17 | protected $lawyers = []; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * @var Generator|DetailLawyer[] |
||
| 21 | */ |
||
| 22 | protected $detailLawyers; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @var int |
||
| 26 | */ |
||
| 27 | protected $page = 1; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @var int |
||
| 31 | */ |
||
| 32 | protected $totalPage = 1; |
||
| 33 | |||
| 34 | /** |
||
| 35 | * @var int |
||
| 36 | */ |
||
| 37 | protected $total = 0; |
||
| 38 | |||
| 39 | /** |
||
| 40 | * @return array |
||
| 41 | */ |
||
| 42 | 1 | public function getLawyers(): array |
|
| 43 | { |
||
| 44 | 1 | return $this->lawyers; |
|
| 45 | } |
||
| 46 | |||
| 47 | /** |
||
| 48 | * @param array $lawyers |
||
| 49 | * |
||
| 50 | * @return FindResponse |
||
| 51 | */ |
||
| 52 | 1 | public function setLawyers(array $lawyers): FindResponse |
|
| 53 | { |
||
| 54 | 1 | $this->lawyers = $lawyers; |
|
| 55 | |||
| 56 | 1 | return $this; |
|
| 57 | } |
||
| 58 | |||
| 59 | /** |
||
| 60 | * @return int |
||
| 61 | */ |
||
| 62 | 1 | public function getPage(): int |
|
| 63 | { |
||
| 64 | 1 | return $this->page; |
|
| 65 | } |
||
| 66 | |||
| 67 | /** |
||
| 68 | * @param int $page |
||
| 69 | * |
||
| 70 | * @return FindResponse |
||
| 71 | */ |
||
| 72 | 1 | public function setPage(int $page): FindResponse |
|
| 73 | { |
||
| 74 | 1 | $this->page = $page; |
|
| 75 | |||
| 76 | 1 | return $this; |
|
| 77 | } |
||
| 78 | |||
| 79 | /** |
||
| 80 | * @return int |
||
| 81 | */ |
||
| 82 | 1 | public function getTotalPage(): int |
|
| 83 | { |
||
| 84 | 1 | return $this->totalPage; |
|
| 85 | } |
||
| 86 | |||
| 87 | /** |
||
| 88 | * @param int $totalPage |
||
| 89 | * |
||
| 90 | * @return FindResponse |
||
| 91 | */ |
||
| 92 | 1 | public function setTotalPage(int $totalPage): FindResponse |
|
| 93 | { |
||
| 94 | 1 | $this->totalPage = $totalPage; |
|
| 95 | |||
| 96 | 1 | return $this; |
|
| 97 | } |
||
| 98 | |||
| 99 | /** |
||
| 100 | * @return int |
||
| 101 | */ |
||
| 102 | 1 | public function getTotal(): int |
|
| 103 | { |
||
| 104 | 1 | return $this->total; |
|
| 105 | } |
||
| 106 | |||
| 107 | /** |
||
| 108 | * @param int $total |
||
| 109 | * |
||
| 110 | * @return FindResponse |
||
| 111 | */ |
||
| 112 | 1 | public function setTotal(int $total): FindResponse |
|
| 113 | { |
||
| 114 | 1 | $this->total = $total; |
|
| 115 | |||
| 116 | 1 | return $this; |
|
| 117 | } |
||
| 118 | |||
| 119 | /** |
||
| 120 | * @param \SomeWork\Minjust\Entity\Lawyer $lawyer |
||
| 121 | * |
||
| 122 | * @return FindResponse |
||
| 123 | */ |
||
| 124 | 1 | public function addLawyer(Lawyer $lawyer): self |
|
| 125 | { |
||
| 126 | 1 | $this->lawyers[] = $lawyer; |
|
| 127 | |||
| 128 | 1 | return $this; |
|
| 129 | } |
||
| 130 | |||
| 131 | /** |
||
| 132 | * @return Generator|DetailLawyer[] |
||
| 133 | */ |
||
| 134 | 1 | public function getDetailLawyers() |
|
| 137 | } |
||
| 138 | |||
| 139 | /** |
||
| 140 | * @param Generator|DetailLawyer[] $detailLawyers |
||
| 141 | * |
||
| 142 | * @return static |
||
| 143 | */ |
||
| 144 | 1 | public function setDetailLawyersGenerator(Generator $detailLawyers): self |
|
| 145 | { |
||
| 149 | } |
||
| 150 | } |
||
| 151 |