| 1 | <?php |
||
| 21 | trait MessageQueryTrait |
||
| 22 | { |
||
| 23 | use MutualQueryTrait; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * Specify unread message. |
||
| 27 | * @return \static $this |
||
| 28 | */ |
||
| 29 | 2 | public function unread() |
|
| 34 | |||
| 35 | /** |
||
| 36 | * Specify read message. |
||
| 37 | * @return \static $this |
||
| 38 | */ |
||
| 39 | 2 | public function read() |
|
| 44 | |||
| 45 | /** |
||
| 46 | * Specify unreceived message. |
||
| 47 | * @return \static $this |
||
| 48 | */ |
||
| 49 | 2 | public function unreceived() |
|
| 54 | |||
| 55 | /** |
||
| 56 | * Specify received message. |
||
| 57 | * @return \static $this |
||
| 58 | */ |
||
| 59 | 2 | public function received() |
|
| 64 | } |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: