1 | <?php |
||
14 | abstract class AbstractParser |
||
15 | { |
||
16 | |||
17 | /** |
||
18 | * @var AbstractScraper |
||
19 | */ |
||
20 | protected $scraper; |
||
21 | |||
22 | /** |
||
23 | * @var Crawler |
||
24 | */ |
||
25 | protected $crawler; |
||
26 | |||
27 | /** |
||
28 | * @var null|boolean |
||
29 | */ |
||
30 | protected $isValidContent = null; |
||
31 | |||
32 | /** |
||
33 | * @var null|AbstractContent |
||
34 | */ |
||
35 | protected $contents = null; |
||
36 | |||
37 | /** |
||
38 | * @return mixed |
||
39 | */ |
||
40 | public function getContent() |
||
53 | |||
54 | abstract protected function generateContent(); |
||
55 | |||
56 | /** |
||
57 | * @return bool|null |
||
58 | */ |
||
59 | public function isValidContent() |
||
68 | |||
69 | /** |
||
70 | * @return void |
||
71 | */ |
||
72 | protected function doValidation() |
||
75 | |||
76 | /** |
||
77 | * @return AbstractScraper |
||
78 | */ |
||
79 | public function getScraper() |
||
83 | |||
84 | /** |
||
85 | * @param AbstractScraper $scraper |
||
86 | */ |
||
87 | public function setScraper($scraper) |
||
91 | |||
92 | /** |
||
93 | * @return Crawler |
||
94 | */ |
||
95 | public function getCrawler(): Crawler |
||
99 | |||
100 | /** |
||
101 | * @param Crawler $crawler |
||
102 | */ |
||
103 | public function setCrawler(Crawler $crawler) |
||
107 | |||
108 | /** |
||
109 | * @return array |
||
110 | */ |
||
111 | public function getArray() |
||
115 | |||
116 | /** |
||
117 | * @return AbstractModel |
||
118 | */ |
||
119 | public function getModel() |
||
127 | |||
128 | /** |
||
129 | * @return AbstractModel |
||
130 | */ |
||
131 | public function getNewModel() |
||
138 | |||
139 | abstract public function getModelClassName(); |
||
140 | |||
141 | /** |
||
142 | * @return string |
||
143 | */ |
||
144 | protected function getContentClassName() |
||
148 | } |
||
149 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..