ActionMapper.php
1 <?php
2 /**
3  * wCMF - wemove Content Management Framework
4  * Copyright (C) 2005-2017 wemove digital solutions GmbH
5  *
6  * Licensed under the terms of the MIT License.
7  *
8  * See the LICENSE file distributed with this work for
9  * additional information.
10  */
11 namespace wcmf\lib\presentation;
12 
14 
15 /**
16  * ActionMapper implementations are responsible for instantiating and
17  * executing Controllers based on the referring Controller and the given action.
18  *
19  * @author ingo herwig <ingo@wemove.com>
20  */
21 interface ActionMapper {
22 
23  /**
24  * Process an action depending on a given referrer. The ActionMapper will instantiate the required Controller class
25  * as determined by the request's action key and delegates the request to it.
26  * @note This method is static so that it can be used without an instance. (This is necessary to call it in onError() which
27  * cannot be a class method because php's set_error_handler() does not allow this).
28  * @param $request The Request instance
29  * @param $response The Response instance
30  */
31  public function processAction(Request $request, Response $response);
32 }
33 ?>
Response holds the response values that are used as output from Controller instances.
Definition: Response.php:20
processAction(Request $request, Response $response)
Process an action depending on a given referrer.
Presentation related interfaces and classes.
Definition: namespaces.php:59
Request holds the request values that are used as input to Controller instances.
Definition: Request.php:18
ActionMapper implementations are responsible for instantiating and executing Controllers based on the...