1 | <?php |
||
10 | final class Sms implements Resource, Blacklistable |
||
11 | { |
||
12 | use Type; |
||
13 | use Blacklisted; |
||
14 | |||
15 | private $countryCode; |
||
16 | |||
17 | private $number; |
||
18 | |||
19 | public function __construct( |
||
30 | |||
31 | public function __toString() |
||
35 | |||
36 | public function countryCode() |
||
40 | |||
41 | public function number() |
||
45 | |||
46 | public function enabled() |
||
50 | |||
51 | public function render($prependCountryCode = true) |
||
58 | } |
||
59 |
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: