-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRequestContextInterface.php
More file actions
74 lines (69 loc) · 1.83 KB
/
RequestContextInterface.php
File metadata and controls
74 lines (69 loc) · 1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<?php
/**
* File defining Backend\Interfaces\RequestContextInterface.
*
* PHP Version 5.3
*
* @category Backend
* @package Interfaces
* @author J Jurgens du Toit <jrgns@backend-php.net>
* @copyright 2011 - 2012 Jade IT (cc)
* @license http://www.opensource.org/licenses/mit-license.php MIT License
* @link http://backend-php.net
*/
namespace Backend\Interfaces;
/**
* Class to define the context of a Request.
*
* @category Backend
* @package Interfaces
* @author J Jurgens du Toit <jrgns@backend-php.net>
* @license http://www.opensource.org/licenses/mit-license.php MIT License
* @link http://backend-php.net
*/
interface RequestContextInterface
{
/**
* The class constructor.
*
* @param \Backend\Interfaces\RequestInterface $request The request from which
* the context is derived.
*/
public function __construct(RequestInterface $request);
/**
* Get the Request scheme.
*
* If the Request URL was, http://backend-php.net/folder/index.php/path,
* this will return http
*
* @return string
*/
public function getScheme();
/**
* Get the hostname of the Request.
*
* If the Request URL was, http://backend-php.net/folder/index.php/path,
* this will return backend-php.net
*
* @return string
*/
public function getHost();
/**
* Get the folder of the Request.
*
* If the Request URL was, http://backend-php.net/folder/index.php/path,
* this will return /folder
*
* @return string
*/
public function getFolder();
/**
* Get a link to the base site of the Request.
*
* If the Request URL was, http://backend-php.net/folder/index.php/path,
* this will return http://backend-php.net/
*
* @return string
*/
public function getLink();
}