[TASK] Extbase: Raised version to 1.1.0alpha1
[Packages/TYPO3.CMS.git] / typo3 / sysext / extbase / Classes / MVC / Controller / ControllerContext.php
1 <?php
2 /***************************************************************
3 * Copyright notice
4 *
5 * (c) 2009 Jochen Rau <jochen.rau@typoplanet.de>
6 * All rights reserved
7 *
8 * This class is a backport of the corresponding class of FLOW3.
9 * All credits go to the v5 team.
10 *
11 * This script is part of the TYPO3 project. The TYPO3 project is
12 * free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2 of the License, or
15 * (at your option) any later version.
16 *
17 * The GNU General Public License can be found at
18 * http://www.gnu.org/copyleft/gpl.html.
19 *
20 * This script is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 * GNU General Public License for more details.
24 *
25 * This copyright notice MUST APPEAR in all copies of the script!
26 ***************************************************************/
27
28 /**
29 * The controller context contains information from the controller
30 *
31 * @package Extbase
32 * @subpackage MVC\Controller
33 * @version $Id$
34 * @license http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public License, version 3 or later
35 * @scope prototype
36 * @api
37 */
38 class Tx_Extbase_MVC_Controller_ControllerContext {
39
40 /**
41 * @var Tx_Extbase_MVC_Request
42 */
43 protected $request;
44
45 /**
46 * @var Tx_Extbase_MVC_Response
47 */
48 protected $response;
49
50 /**
51 * @var Tx_Extbase_MVC_Controller_Arguments
52 */
53 protected $arguments;
54
55 /**
56 * @var Tx_Extbase_Property_MappingResults
57 */
58 protected $argumentsMappingResults;
59
60 /**
61 * @var Tx_Extbase_MVC_Web_Routing_UriBuilder
62 */
63 protected $uriBuilder;
64
65 /**
66 * @var Tx_Extbase_MVC_Controller_FlashMessages
67 */
68 protected $flashMessages;
69
70 /**
71 * Set the request of the controller
72 *
73 * @param Tx_Extbase_MVC_Request $request
74 * @return void
75 */
76 public function setRequest(Tx_Extbase_MVC_Request $request) {
77 $this->request = $request;
78 }
79
80 /**
81 * Get the request of the controller
82 *
83 * @return Tx_Extbase_MVC_Request
84 * @api
85 */
86 public function getRequest() {
87 return $this->request;
88 }
89
90 /**
91 * Set the response of the controller
92 *
93 * @param Tx_Extbase_MVC_Response $request
94 * @return void
95 */
96 public function setResponse(Tx_Extbase_MVC_Response $response) {
97 $this->response = $response;
98 }
99
100 /**
101 * Get the response of the controller
102 *
103 * @return Tx_Extbase_MVC_Request
104 * @api
105 */
106 public function getResponse() {
107 return $this->response;
108 }
109
110 /**
111 * Set the arguments of the controller
112 *
113 * @param Tx_Extbase_MVC_Controller_Arguments $arguments
114 * @return void
115 */
116 public function setArguments(Tx_Extbase_MVC_Controller_Arguments $arguments) {
117 $this->arguments = $arguments;
118 }
119
120 /**
121 * Get the arguments of the controller
122 *
123 * @return Tx_Extbase_MVC_Controller_Arguments
124 * @api
125 */
126 public function getArguments() {
127 return $this->arguments;
128 }
129
130 /**
131 * Set the arguments mapping results of the controller
132 *
133 * @param Tx_Extbase_Property_MappingResults $argumentsMappingResults
134 * @return void
135 */
136 public function setArgumentsMappingResults(Tx_Extbase_Property_MappingResults $argumentsMappingResults) {
137 $this->argumentsMappingResults = $argumentsMappingResults;
138 }
139
140 /**
141 * Get the arguments mapping results of the controller
142 *
143 * @return Tx_Extbase_Property_MappingResults
144 * @api
145 */
146 public function getArgumentsMappingResults() {
147 return $this->argumentsMappingResults;
148 }
149
150 /**
151 * Tx_Extbase_MVC_Web_Routing_UriBuilder $uriBuilder
152 * @return void
153 */
154 public function setUriBuilder(Tx_Extbase_MVC_Web_Routing_UriBuilder $uriBuilder) {
155 $this->uriBuilder = $uriBuilder;
156 }
157
158 /**
159 * @return Tx_Extbase_MVC_Web_Routing_UriBuilder
160 * @api
161 */
162 public function getUriBuilder() {
163 return $this->uriBuilder;
164 }
165
166 /**
167 * Set the flash messages
168 *
169 * @param Tx_Extbase_MVC_Controller_FlashMessages $flashMessages
170 * @return void
171 */
172 public function setFlashMessages(Tx_Extbase_MVC_Controller_FlashMessages $flashMessages) {
173 $this->flashMessages = $flashMessages;
174 }
175
176 /**
177 * Get the flash messages
178 *
179 * @return Tx_Extbase_MVC_Controller_FlashMessages
180 * @api
181 */
182 public function getFlashMessages() {
183 return $this->flashMessages;
184 }
185
186 /**
187 * Get the flash messages
188 *
189 * @return Tx_Extbase_MVC_Controller_FlashMessages
190 */
191 public function getFlashMessageContainer() {
192 return $this->flashMessages;
193 }
194 }
195 ?>