1 | <?php |
||
12 | class WebApplication extends AbstractWebApplication |
||
13 | { |
||
14 | /** |
||
15 | * Response mime type. |
||
16 | * |
||
17 | * @var string |
||
18 | * @since 1.0 |
||
19 | */ |
||
20 | public $mimeType = 'application/json'; |
||
21 | |||
22 | /** |
||
23 | * Application router. |
||
24 | * |
||
25 | * @var Router |
||
26 | * @since 1.0 |
||
27 | */ |
||
28 | private $router; |
||
29 | |||
30 | /** |
||
31 | * Method to run the application routines. |
||
32 | * |
||
33 | * @return void |
||
34 | * |
||
35 | * @since 1.0 |
||
36 | */ |
||
37 | 5 | public function doExecute() |
|
61 | |||
62 | /** |
||
63 | * Set the HTTP Response Header for error conditions. |
||
64 | * |
||
65 | * @param \Exception $exception The Exception object to process. |
||
66 | * |
||
67 | * @return void |
||
68 | * |
||
69 | * @since 1.0 |
||
70 | */ |
||
71 | 4 | private function setErrorHeader(\Exception $exception) |
|
97 | |||
98 | /** |
||
99 | * Set the application's router. |
||
100 | * |
||
101 | * @param Router $router Router object to set. |
||
102 | * |
||
103 | * @return $this |
||
104 | * |
||
105 | * @since 1.0 |
||
106 | */ |
||
107 | 1 | public function setRouter(Router $router) |
|
113 | } |
||
114 |