1 | <?php |
||
16 | final class CashGame implements Game |
||
17 | { |
||
18 | /** |
||
19 | * @var UuidInterface |
||
20 | */ |
||
21 | private $id; |
||
22 | |||
23 | /** |
||
24 | * @var string |
||
25 | */ |
||
26 | private $name; |
||
27 | |||
28 | /** |
||
29 | * @var DefaultParameters |
||
30 | */ |
||
31 | private $rules; |
||
32 | |||
33 | /** |
||
34 | * @var PlayerCollection |
||
35 | */ |
||
36 | private $players; |
||
37 | |||
38 | /** |
||
39 | * @var TableCollection |
||
40 | */ |
||
41 | protected $tables; |
||
42 | |||
43 | /** |
||
44 | * CashGame constructor. |
||
45 | * |
||
46 | * @param UuidInterface $id |
||
47 | * @param string $name |
||
48 | * @param GameParameters $rules |
||
49 | 66 | */ |
|
50 | public function __construct(UuidInterface $id, string $name, GameParameters $rules) |
||
58 | |||
59 | /** |
||
60 | * @param UuidInterface $id |
||
61 | * @param string $name |
||
62 | * @param GameParameters $rules |
||
63 | * |
||
64 | * @return CashGame |
||
65 | 66 | */ |
|
66 | public static function setUp(UuidInterface $id, string $name, GameParameters $rules) |
||
70 | |||
71 | /** |
||
72 | * @return UuidInterface |
||
73 | 1 | */ |
|
74 | public function id(): UuidInterface |
||
78 | |||
79 | /** |
||
80 | * @return string |
||
81 | 1 | */ |
|
82 | public function name(): string |
||
86 | |||
87 | /** |
||
88 | * @return GameParameters |
||
89 | 4 | */ |
|
90 | public function rules(): GameParameters |
||
94 | |||
95 | /** |
||
96 | * @return PlayerCollection |
||
97 | 63 | */ |
|
98 | public function players(): PlayerCollection |
||
102 | |||
103 | /** |
||
104 | * @return string |
||
105 | */ |
||
106 | public function __toString(): string |
||
110 | 62 | ||
111 | /** |
||
112 | 62 | * @return TableCollection |
|
113 | */ |
||
114 | 59 | public function tables(): TableCollection |
|
118 | 1 | ||
119 | /** |
||
120 | * @param Client $client |
||
121 | 62 | * @param Chips $buyinAmount |
|
122 | 1 | * |
|
123 | * @throws GameException |
||
124 | */ |
||
125 | 61 | public function registerPlayer(Client $client, Chips $buyinAmount = null) |
|
147 | 57 | ||
148 | 57 | public function removePlayer(Client $client) |
|
165 | |||
166 | public function assignPlayersToTables() |
||
180 | } |
||
181 |
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..