Completed
Push — master ( 8eb315...5aaba6 )
by Changwan
04:29
created

SqsJob::__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
cc 1
eloc 3
c 0
b 0
f 0
nc 1
nop 2
dl 0
loc 5
ccs 0
cts 5
cp 0
crap 2
rs 9.4285
1
<?php
2
namespace Wandu\Q\Adapter;
3
4
use Wandu\Q\Contracts\AdapterJob;
5
6
class SqsJob implements AdapterJob
7
{
8
    /** @var string */
9
    protected $receiptHandler;
10
    
11
    /** @var string */
12
    protected $body;
13
14
    public function __construct($receiptHandler, $body)
15
    {
16
        $this->receiptHandler = $receiptHandler;
17
        $this->body = $body;
18
    }
19
20
    /**
21
     * @return string
22
     */
23
    public function getReceiptHandler()
24
    {
25
        return $this->receiptHandler;
26
    }
27
    
28
    /**
29
     * {@inheritdoc}
30
     */
31
    public function payload(): string
32
    {
33
        return $this->body;
34
    }
35
}
36