| 1 | <?php |
||
| 15 | class Tree implements JsonSerializable { |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @var float |
||
| 19 | */ |
||
| 20 | public $height; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @var string |
||
| 24 | */ |
||
| 25 | private $name; |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @var BranchClass |
||
| 29 | */ |
||
| 30 | private $branch; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @var BranchClass |
||
| 34 | */ |
||
| 35 | private $something; |
||
| 36 | |||
| 37 | /** |
||
| 38 | * @return float |
||
| 39 | */ |
||
| 40 | public function getHeight() { |
||
| 43 | |||
| 44 | /** |
||
| 45 | * @param float $height |
||
| 46 | * @return $this |
||
| 47 | */ |
||
| 48 | public function setHeight($height) { |
||
| 53 | |||
| 54 | /** |
||
| 55 | * @return string |
||
| 56 | */ |
||
| 57 | public function getName() { |
||
| 60 | |||
| 61 | /** |
||
| 62 | * @param string $name |
||
| 63 | * @return $this |
||
| 64 | */ |
||
| 65 | public function setName($name) { |
||
| 70 | |||
| 71 | /** |
||
| 72 | * @return BranchClass |
||
| 73 | */ |
||
| 74 | public function getBranch() { |
||
| 77 | |||
| 78 | /** |
||
| 79 | * @param BranchClass $branch |
||
| 80 | * @return $this |
||
| 81 | */ |
||
| 82 | public function setBranch(BranchClass $branch = null) { |
||
| 87 | |||
| 88 | /** |
||
| 89 | * @param double $height |
||
| 90 | * @param string $name |
||
| 91 | * @param BranchClass $branch |
||
| 92 | */ |
||
| 93 | public function __construct($height = null, $name = null, BranchClass $branch = null) { |
||
| 99 | |||
| 100 | /** |
||
| 101 | * @return array |
||
| 102 | */ |
||
| 103 | public function jsonSerialize() { |
||
| 110 | |||
| 111 | } |
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..