Total Complexity | 3 |
Total Lines | 34 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | class Functions |
||
8 | { |
||
9 | /** |
||
10 | * Method responsible for returning the |
||
11 | * active RouteCollection instance. |
||
12 | * |
||
13 | * @return null|\MinasRouter\Router\RouteCollection |
||
14 | */ |
||
15 | protected function collection() |
||
16 | { |
||
17 | return Route::$collection; |
||
18 | } |
||
19 | |||
20 | /** |
||
21 | * Method responsible for returning a route. |
||
22 | * |
||
23 | * @param string $name |
||
24 | * |
||
25 | * @return null|\MinasRouter\Router\RouteManager |
||
26 | */ |
||
27 | public function get(String $routerName) |
||
28 | { |
||
29 | return $this->collection()->getByName($routerName); |
||
30 | } |
||
31 | |||
32 | /** |
||
33 | * Method responsible for returning the |
||
34 | * current route. |
||
35 | * |
||
36 | * @return null|\MinasRouter\Router\RouteManager |
||
37 | */ |
||
38 | public function current() |
||
41 | } |
||
42 | } |