| Total Complexity | 8 |
| Total Lines | 89 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 7 | class HttpServerDoc extends ServerDoc |
||
| 8 | { |
||
| 9 | /** @var string|null */ |
||
| 10 | private $endpoint = null; |
||
| 11 | /** @var string|null */ |
||
| 12 | private $host = null; |
||
| 13 | /** @var string|null */ |
||
| 14 | private $basePath = null; |
||
| 15 | /** @var string[] */ |
||
| 16 | private $schemeList = []; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @param string $endpoint |
||
| 20 | * |
||
| 21 | * @return self |
||
| 22 | */ |
||
| 23 | 2 | public function setEndpoint(string $endpoint) : self |
|
| 24 | { |
||
| 25 | 2 | $this->endpoint = $endpoint; |
|
| 26 | |||
| 27 | 2 | return $this; |
|
| 28 | } |
||
| 29 | |||
| 30 | /** |
||
| 31 | * @param string $host |
||
| 32 | * |
||
| 33 | * @return self |
||
| 34 | */ |
||
| 35 | 2 | public function setHost(string $host) : self |
|
| 36 | { |
||
| 37 | 2 | $this->host = $host; |
|
| 38 | |||
| 39 | 2 | return $this; |
|
| 40 | } |
||
| 41 | |||
| 42 | /** |
||
| 43 | * @param string $basePath |
||
| 44 | * |
||
| 45 | * @return self |
||
| 46 | */ |
||
| 47 | 2 | public function setBasePath(string $basePath) : self |
|
| 48 | { |
||
| 49 | 2 | $this->basePath = $basePath; |
|
| 50 | |||
| 51 | 2 | return $this; |
|
| 52 | } |
||
| 53 | |||
| 54 | /** |
||
| 55 | * @param string[] $schemeList |
||
| 56 | * |
||
| 57 | * @return self |
||
| 58 | */ |
||
| 59 | 2 | public function setSchemeList(array $schemeList) : self |
|
| 60 | { |
||
| 61 | 2 | $this->schemeList = $schemeList; |
|
| 62 | |||
| 63 | 2 | return $this; |
|
| 64 | } |
||
| 65 | |||
| 66 | /** |
||
| 67 | * @return string|null |
||
| 68 | */ |
||
| 69 | 1 | public function getEndpoint() : ?string |
|
| 70 | { |
||
| 71 | 1 | return $this->endpoint; |
|
| 72 | } |
||
| 73 | |||
| 74 | /** |
||
| 75 | * @return string|null |
||
| 76 | */ |
||
| 77 | 7 | public function getHost() : ?string |
|
| 78 | { |
||
| 79 | 7 | return $this->host; |
|
| 80 | } |
||
| 81 | |||
| 82 | /** |
||
| 83 | * @return string|null |
||
| 84 | */ |
||
| 85 | 7 | public function getBasePath() : ?string |
|
| 88 | } |
||
| 89 | |||
| 90 | /** |
||
| 91 | * @return string[] |
||
| 92 | */ |
||
| 93 | 7 | public function getSchemeList() : array |
|
| 96 | } |
||
| 97 | } |
||
| 98 |