1 | <?php |
||
10 | class Boolean implements ValueObjectInterface |
||
11 | { |
||
12 | /** |
||
13 | * @var \ValueObjects\StringLiteral\StringLiteral |
||
14 | */ |
||
15 | private $boolean; |
||
16 | |||
17 | /** |
||
18 | * Returns a Name objects form PHP native values |
||
19 | * |
||
20 | * @param string $value |
||
|
|||
21 | * |
||
22 | * @return static |
||
23 | */ |
||
24 | public static function fromNative() |
||
30 | |||
31 | /** |
||
32 | * Returns a Boolean object |
||
33 | * |
||
34 | * @param StringLiteral $boolean |
||
35 | */ |
||
36 | public function __construct(StringLiteral $boolean) |
||
44 | |||
45 | /** |
||
46 | * Tells whether two booleans are equal by comparing their values |
||
47 | * |
||
48 | * @param ValueObjectInterface $boolean |
||
49 | * |
||
50 | * @return bool |
||
51 | */ |
||
52 | public function sameValueAs(ValueObjectInterface $boolean) |
||
60 | |||
61 | /** |
||
62 | * Returns the bool value of the boolean |
||
63 | * |
||
64 | * @return bool |
||
65 | */ |
||
66 | public function toBool() |
||
70 | |||
71 | /** |
||
72 | * Returns the string value of the boolean |
||
73 | * |
||
74 | * @return string |
||
75 | */ |
||
76 | public function toNative() |
||
80 | |||
81 | /** |
||
82 | * Returns the string value of the boolean |
||
83 | * |
||
84 | * @return string |
||
85 | */ |
||
86 | public function __toString() |
||
90 | } |
||
91 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.