PushSettings   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 56
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 4
lcom 0
cbo 1
dl 0
loc 56
ccs 13
cts 13
cp 1
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 9 1
A getInputQueue() 0 4 1
A getErrorQueue() 0 4 1
A isPurgeOnStartup() 0 4 1
1
<?php
2
namespace PSB\Core\Transport;
3
4
5
use PSB\Core\Util\Guard;
6
7
class PushSettings
8
{
9
    /**
10
     * @var string
11
     */
12
    private $inputQueue;
13
14
    /**
15
     * @var string
16
     */
17
    private $errorQueue;
18
19
    /**
20
     * @var bool
21
     */
22
    private $purgeOnStartup;
23
24
    /**
25
     * @param string $inputQueue
26
     * @param string $errorQueue
27
     * @param bool   $purgeOnStartup
28
     */
29 6
    public function __construct($inputQueue, $errorQueue, $purgeOnStartup)
30
    {
31 6
        Guard::againstNullAndEmpty('inputQueue', $inputQueue);
32 5
        Guard::againstNullAndEmpty('errorQueue', $errorQueue);
33
34 4
        $this->inputQueue = $inputQueue;
35 4
        $this->errorQueue = $errorQueue;
36 4
        $this->purgeOnStartup = $purgeOnStartup;
37 4
    }
38
39
    /**
40
     * @return string
41
     */
42 1
    public function getInputQueue()
43
    {
44 1
        return $this->inputQueue;
45
    }
46
47
    /**
48
     * @return string
49
     */
50 1
    public function getErrorQueue()
51
    {
52 1
        return $this->errorQueue;
53
    }
54
55
    /**
56
     * @return boolean
57
     */
58 1
    public function isPurgeOnStartup()
59
    {
60 1
        return $this->purgeOnStartup;
61
    }
62
}
63