Test Failed
Branch improve-scrutinizer (33a448)
by Ayan
02:51
created

Routed   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 16
rs 10
c 0
b 0
f 0
wmc 2
1
<?php
2
3
namespace Phprest\Stub\Controller;
4
5
use Phprest\Annotation as Phprest;
6
use Phprest\Response;
7
use Phprest\Util\Controller as BaseController;
8
9
class Routed extends BaseController
10
{
11
    /**
12
     * @Phprest\Route(method="GET", path="/foos/{id}", since=1.2, until=2.8)
13
     */
14
    public static function getFoo()
15
    {
16
        return new Response\Ok('Hello World!');
17
    }
18
19
    /**
20
     * @Phprest\Route(method="POST", path="bars", since=0.5, until=0.7)
21
     */
22
    public static function postBar()
23
    {
24
        return new Response\Created('sample location');
25
    }
26
}
27