Passed
Push — master ( a3f40e...f6b1e4 )
by Jean-Bernard
01:40
created

ResponseParameters::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 5
c 0
b 0
f 0
ccs 0
cts 4
cp 0
rs 9.4285
cc 1
eloc 3
nc 1
nop 2
crap 2
1
<?php
2
3
/*
4
 * This file is part of the Symfony-Util package.
5
 *
6
 * (c) Jean-Bernard Addor
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace SymfonyUtil\Component\HttpFoundation;
13
14
use Symfony\Component\HttpFoundation\Response;
15
16
class ResponseParameters implements ResponseParametersInterface
17
{
18
    protected $parameters;
19
    protected $response;
20
21
    public function __construct(array $parameters, Response $response = null)
22
    {
23
        $this->parameters = $parameters;
24
        $this->response = $response;
25
    }
26
27
    public function getParameters()
28
    {
29
        return $this->parameters; // array
30
    }
31
32
    public function getResponse()
33
    {
34
        return $this->response; // Response or null
35
    }
36
}
37