1 | <?php |
||
18 | class Response implements ResponseInterface |
||
19 | { |
||
20 | |||
21 | /** |
||
22 | * @var array $notice |
||
23 | */ |
||
24 | protected $notice = array(); |
||
25 | |||
26 | /** |
||
27 | * rendered output to be returned to WP |
||
28 | * |
||
29 | * @var string $output |
||
30 | */ |
||
31 | protected $output = ''; |
||
32 | |||
33 | /** |
||
34 | * @var bool |
||
35 | */ |
||
36 | protected $request_terminated = false; |
||
37 | |||
38 | /** |
||
39 | * @var bool $deactivate_plugin |
||
40 | */ |
||
41 | protected $deactivate_plugin = false; |
||
42 | |||
43 | |||
44 | /** |
||
45 | * EE_Response constructor. |
||
46 | */ |
||
47 | public function __construct() |
||
51 | |||
52 | |||
53 | |||
54 | /** |
||
55 | * @param $key |
||
56 | * @param $value |
||
57 | * @return void |
||
58 | */ |
||
59 | public function setNotice($key, $value) |
||
63 | |||
64 | |||
65 | |||
66 | /** |
||
67 | * @param $key |
||
68 | * @return mixed |
||
69 | */ |
||
70 | public function getNotice($key) |
||
74 | |||
75 | |||
76 | |||
77 | /** |
||
78 | * @return array |
||
79 | */ |
||
80 | public function getNotices() |
||
84 | |||
85 | |||
86 | |||
87 | /** |
||
88 | * @param string $string |
||
89 | * @param bool $append |
||
90 | */ |
||
91 | public function addOutput($string, $append = true) |
||
95 | |||
96 | |||
97 | |||
98 | /** |
||
99 | * @return string |
||
100 | */ |
||
101 | public function getOutput() |
||
105 | |||
106 | |||
107 | |||
108 | /** |
||
109 | * @return boolean |
||
110 | */ |
||
111 | public function requestTerminated() |
||
115 | |||
116 | |||
117 | |||
118 | /** |
||
119 | * @param boolean $request_terminated |
||
120 | */ |
||
121 | public function terminateRequest($request_terminated = true) |
||
125 | |||
126 | |||
127 | |||
128 | /** |
||
129 | * @return boolean |
||
130 | */ |
||
131 | public function pluginDeactivated() |
||
135 | |||
136 | |||
137 | |||
138 | /** |
||
139 | * sets $deactivate_plugin to true |
||
140 | */ |
||
141 | public function deactivatePlugin() |
||
145 | |||
146 | |||
147 | } |
||
148 | // End of file EE_Response.core.php |
||
150 |