1 | <?php |
||
5 | class IcsContent implements Content |
||
6 | { |
||
7 | /** |
||
8 | * @var string |
||
9 | */ |
||
10 | private $value; |
||
11 | |||
12 | /** |
||
13 | * @param string $value |
||
14 | */ |
||
15 | function __construct(string $value) |
||
19 | |||
20 | /** |
||
21 | * @return string |
||
22 | */ |
||
23 | public function asString(): string |
||
27 | |||
28 | /** |
||
29 | * @return ContentType |
||
30 | */ |
||
31 | public function getContentType(): ContentType |
||
35 | } |
Adding explicit visibility (
private
,protected
, orpublic
) is generally recommend to communicate to other developers how, and from where this method is intended to be used.