Bag   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 37
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 0

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 0
dl 0
loc 37
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getDom() 0 4 1
A getRows() 0 4 1
1
<?php
2
3
/**
4
 * This file is part of Laravel Meetups.
5
 *
6
 * (c) Nuno Maduro <[email protected]>
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 LaravelMeetups\Jobs\Catalog;
13
14
use LaravelMeetups\Contracts\Jobs\Catalog\Bag as Contract;
15
use PHPHtmlParser\Dom;
16
17
/**
18
 * Class Bag.
19
 */
20
class Bag implements Contract
21
{
22
    /**
23
     * @var Dom
24
     */
25
    private $dom;
26
27
    /**
28
     * @var array
29
     */
30
    private $rows;
31
32
    /**
33
     * {@inheritdoc}
34
     */
35
    public function __construct(Dom $dom, array $rows)
36
    {
37
        $this->dom = $dom;
38
        $this->rows = $rows;
39
    }
40
41
    /**
42
     * {@inheritdoc}
43
     */
44
    public function getDom()
45
    {
46
        return clone $this->dom;
47
    }
48
49
    /**
50
     * {@inheritdoc}
51
     */
52
    public function getRows()
53
    {
54
        return $this->rows;
55
    }
56
}
57