Passed
Push — master ( f17b13...8bf1e0 )
by Radu
01:33
created

Method   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 18
dl 0
loc 27
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A getSupported() 0 11 1
1
<?php
2
namespace WebServCo\Framework\Http;
3
4
final class Method
5
{
6
    const GET = 'GET';
7
    const HEAD = 'HEAD';
8
    const POST = 'POST';
9
    const PUT = 'PUT';
10
    const DELETE = 'DELETE';
11
    const CONNECT = 'CONNECT';
12
    const OPTIONS = 'OPTIONS';
13
    const TRACE = 'TRACE';
14
15
    /**
16
     * Retrieve list of supported HTTP methods.
17
     *
18
     * @return array
19
     */
20
    public static function getSupported()
21
    {
22
        return [
23
            self::GET,
24
            self::HEAD,
25
            self::POST,
26
            self::PUT,
27
            self::DELETE,
28
            self::CONNECT,
29
            self::OPTIONS,
30
            self::TRACE
31
        ];
32
    }
33
}
34