Passed
Push — master ( 617266...2422af )
by Siim
10:33
created

OptionsRequest   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 6
dl 0
loc 26
rs 10
c 0
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getCacheKey() 0 3 1
A getCacheExpiresAfter() 0 3 1
A getCacheTags() 0 3 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: siim
5
 * Date: 17.01.19
6
 * Time: 8:02
7
 */
8
9
namespace Sf4\Api\Request;
10
11
use Sf4\Api\CacheAdapter\CacheKeysInterface;
12
use Sf4\Api\Response\OptionsResponse;
13
14
class OptionsRequest extends AbstractRequest
15
{
16
17
    /**
18
     * OptionsRequest constructor.
19
     */
20
    public function __construct()
21
    {
22
        $this->init(
23
            new OptionsResponse()
24
        );
25
    }
26
27
    protected function getCacheTags(): array
28
    {
29
        return [];
30
    }
31
32
    protected function getCacheExpiresAfter(): ?int
33
    {
34
        return null;
35
    }
36
37
    protected function getCacheKey(): string
38
    {
39
        return CacheKeysInterface::KEY_OPTIONS;
40
    }
41
}
42