| 1 | <?php |
||
| 19 | class ContentObserver |
||
| 20 | { |
||
| 21 | /** |
||
| 22 | * @var ContentRenderInterface |
||
| 23 | */ |
||
| 24 | private $renderer; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * ContentObserver constructor. |
||
| 28 | * |
||
| 29 | * @param ContentRenderInterface $renderer |
||
| 30 | */ |
||
| 31 | public function __construct(ContentRenderInterface $renderer) |
||
| 35 | |||
| 36 | /** |
||
| 37 | * @param Tip $tip |
||
| 38 | */ |
||
| 39 | public function saving(Tip $tip): void |
||
| 47 | } |
||
| 48 |
Since your code implements the magic getter
_get, this function will be called for any read access on an undefined variable. You can add the@propertyannotation to your class or interface to document the existence of this variable.If the property has read access only, you can use the @property-read annotation instead.
Of course, you may also just have mistyped another name, in which case you should fix the error.
See also the PhpDoc documentation for @property.