Test Setup Failed
Push — master ( fc6567...89d4a6 )
by Gabriel
07:58
created

HasHeadersTrait   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
dl 0
loc 26
ccs 0
cts 5
cp 0
rs 10
c 0
b 0
f 0
wmc 2
lcom 0
cbo 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getHeaders() 0 4 1
A setHeaders() 0 4 1
1
<?php
2
3
namespace Nip\Router\RequestContext\Traits;
4
5
/**
6
 * Trait HasHeadersTrait
7
 * @package Nip\Router\RequestContext\Traits
8
 */
9
trait HasHeadersTrait
10
{
11
12
    /**
13
     * Headers (taken from the $_SERVER).
14
     *
15
     * @var \Symfony\Component\HttpFoundation\HeaderBag
16
     */
17
    protected $headers;
18
19
    /**
20
     * @return \Symfony\Component\HttpFoundation\HeaderBag
21
     */
22
    public function getHeaders(): \Symfony\Component\HttpFoundation\HeaderBag
23
    {
24
        return $this->headers;
25
    }
26
27
    /**
28
     * @param \Symfony\Component\HttpFoundation\HeaderBag $headers
29
     */
30
    public function setHeaders(\Symfony\Component\HttpFoundation\HeaderBag $headers)
31
    {
32
        $this->headers = $headers;
33
    }
34
}
35