Total Complexity | 3 |
Total Lines | 44 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
12 | class Job implements JobIdInterface |
||
13 | { |
||
14 | public const STATUS_READY = 'ready'; |
||
15 | public const STATUS_RESERVED = 'reserved'; |
||
16 | public const STATUS_DELAYED = 'delayed'; |
||
17 | public const STATUS_BURIED = 'buried'; |
||
18 | |||
19 | /** |
||
20 | * @var int |
||
21 | */ |
||
22 | private $id; |
||
23 | /** |
||
24 | * @var string |
||
25 | */ |
||
26 | private $data; |
||
27 | |||
28 | /** |
||
29 | * @param int $id The job ID |
||
30 | * @param string $data The job data |
||
31 | */ |
||
32 | 18 | public function __construct(int $id, string $data) |
|
36 | 18 | } |
|
37 | |||
38 | /** |
||
39 | * The job ID, unique on the beanstalkd server. |
||
40 | * |
||
41 | * @return int |
||
42 | */ |
||
43 | 16 | public function getId(): int |
|
46 | } |
||
47 | |||
48 | /** |
||
49 | * The job data. |
||
50 | * |
||
51 | * @return string |
||
52 | */ |
||
53 | 7 | public function getData(): string |
|
58 |