Completed
Push — master ( 57dab7...a3bee9 )
by Tomáš
05:06
created

ExchangeBind::getRoutingKey()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 4
Ratio 100 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 4
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php declare(strict_types=1);
2
3
namespace Portiny\RabbitMQ\Exchange;
4
5 View Code Duplication
final class ExchangeBind
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
6
{
7
	/**
8
	 * @var string
9
	 */
10
	private $destination;
11
12
	/**
13
	 * @var string
14
	 */
15
	private $routingKey;
16
17
	/**
18
	 * @var bool
19
	 */
20
	private $nowait = false;
21
22
	/**
23
	 * @var array
24
	 */
25
	private $arguments = [];
26
27 4
	public function __construct(
28
		string $destination,
29
		string $routingKey = '',
30
		bool $nowait = false,
31
		array $arguments = []
32
	) {
33 4
		$this->destination = $destination;
34 4
		$this->routingKey = $routingKey;
35 4
		$this->nowait = $nowait;
36 4
		$this->arguments = $arguments;
37 4
	}
38
39 1
	public function getDestination(): string
40
	{
41 1
		return $this->destination;
42
	}
43
44 1
	public function getRoutingKey(): string
45
	{
46 1
		return $this->routingKey;
47
	}
48
49 1
	public function isNowait(): bool
50
	{
51 1
		return $this->nowait;
52
	}
53
54 1
	public function getArguments(): array
55
	{
56 1
		return $this->arguments;
57
	}
58
}
59