| Total Complexity | 6 |
| Total Lines | 46 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 5 | class Request |
||
| 6 | { |
||
| 7 | private $host; |
||
| 8 | private $path; |
||
| 9 | private $userAgent; |
||
| 10 | private $referer; |
||
| 11 | private $scheme; |
||
| 12 | |||
| 13 | /** |
||
| 14 | * @param string $host Host of the URI instance |
||
| 15 | * @param string $path Path of the URI instance |
||
| 16 | * @param string $userAgent User-Agent header of the request |
||
| 17 | * @param string $referer Referer header of the request |
||
| 18 | */ |
||
| 19 | public function __construct($host, $path, $userAgent, $referer = '', $scheme = 'http') |
||
| 20 | { |
||
| 21 | $this->host = $host; |
||
| 22 | $this->path = $path; |
||
| 23 | $this->userAgent = $userAgent; |
||
| 24 | $this->referer = $referer; |
||
| 25 | $this->scheme = $scheme; |
||
| 26 | } |
||
| 27 | |||
| 28 | public function getHost() |
||
| 29 | { |
||
| 30 | return $this->host; |
||
| 31 | } |
||
| 32 | |||
| 33 | public function getPath() |
||
| 34 | { |
||
| 35 | return $this->path; |
||
| 36 | } |
||
| 37 | |||
| 38 | public function getUserAgent() |
||
| 39 | { |
||
| 40 | return $this->userAgent; |
||
| 41 | } |
||
| 42 | |||
| 43 | public function getReferer() |
||
| 46 | } |
||
| 47 | |||
| 48 | public function getScheme() |
||
| 51 | } |
||
| 52 | } |
||
| 53 |