| 1 | <?php |
||
| 22 | class ResultNotFound |
||
| 23 | { |
||
| 24 | /** |
||
| 25 | * Id that was not found |
||
| 26 | * |
||
| 27 | * @var string |
||
| 28 | **/ |
||
| 29 | private $id; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Constructor |
||
| 33 | * |
||
| 34 | * @param string $id |
||
| 35 | * @return void |
||
|
|
|||
| 36 | **/ |
||
| 37 | public function __construct($id) |
||
| 41 | |||
| 42 | /** |
||
| 43 | * Get the id |
||
| 44 | * |
||
| 45 | * @return string |
||
| 46 | */ |
||
| 47 | public function getId() |
||
| 51 | |||
| 52 | /** |
||
| 53 | * Set the id |
||
| 54 | * |
||
| 55 | * @param string $id |
||
| 56 | * @return ResultNotFound |
||
| 57 | */ |
||
| 58 | public function setId($id) |
||
| 64 | |||
| 65 | /** |
||
| 66 | * String overload |
||
| 67 | * |
||
| 68 | * @return void |
||
| 69 | **/ |
||
| 70 | public function __toString() |
||
| 74 | } |
||
| 75 |
Adding a
@returnannotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.