| Total Complexity | 10 |
| Total Lines | 60 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 15 | class Server implements ValueObjectInterface |
||
| 16 | { |
||
| 17 | use CompositeValueObjectWithExtension; |
||
|
|
|||
| 18 | |||
| 19 | /** |
||
| 20 | * @var UrlsWithPlaceholders |
||
| 21 | */ |
||
| 22 | private $url; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @var string|null |
||
| 26 | */ |
||
| 27 | private $description; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @var ServerVariableObjectList|null |
||
| 31 | */ |
||
| 32 | private $variables; |
||
| 33 | |||
| 34 | public function __construct(UrlsWithPlaceholders $url) |
||
| 35 | { |
||
| 36 | $this->url = $url; |
||
| 37 | $this->validateProperties(); |
||
| 38 | } |
||
| 39 | |||
| 40 | public function getUrl(): UrlsWithPlaceholders |
||
| 41 | { |
||
| 42 | return $this->url; |
||
| 43 | } |
||
| 44 | |||
| 45 | /** |
||
| 46 | * @return string|null |
||
| 47 | */ |
||
| 48 | public function getDescription(): ?string |
||
| 49 | { |
||
| 50 | return $this->description; |
||
| 51 | } |
||
| 52 | |||
| 53 | /** |
||
| 54 | * @return ServerVariableObjectList|null |
||
| 55 | */ |
||
| 56 | public function getVariables(): ?ServerVariableObjectList |
||
| 59 | } |
||
| 60 | |||
| 61 | protected function validateProperties(): void |
||
| 62 | { |
||
| 78 |