Passed
Push — master ( 20adb5...15e0f1 )
by Yohann
07:24 queued 05:57
created

Application   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
c 1
b 0
f 0
dl 0
loc 17
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
A run() 0 3 1
1
<?php
2
3
namespace mvc\core;
4
5
class Application
6
{
7
    public Router $router;
8
    public Request $request;
9
    public Response $response;
10
11
    public function __construct()
12
    {
13
        $this->request = new Request();
14
        $this->response = new Response();
15
16
        $this->router = new Router($this->request, $this->response);
17
    }
18
19
    public function run()
20
    {
21
        echo $this->router->resolve();
22
    }
23
}
24