TableReferences::setTableName()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 5
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
declare(strict_types=1);
3
4
namespace Maba\DatabaseInconsistencyFinder\Entity;
5
6
use Doctrine\DBAL\Connection;
7
8
class TableReferences
9
{
10
    /**
11
     * @var Connection
12
     */
13
    private $connection;
14
15
    /**
16
     * @var string
17
     */
18
    private $tableName;
19
20
    /**
21
     * @var string[]
22
     */
23
    private $columnNames;
24
25 12
    public function getConnection(): Connection
26
    {
27 12
        return $this->connection;
28
    }
29
30 12
    public function setConnection(Connection $connection): self
31
    {
32 12
        $this->connection = $connection;
33 12
        return $this;
34
    }
35
36 12
    public function getTableName(): string
37
    {
38 12
        return $this->tableName;
39
    }
40
41 12
    public function setTableName(string $tableName): self
42
    {
43 12
        $this->tableName = $tableName;
44 12
        return $this;
45
    }
46
47
    /**
48
     * @return string[]
49
     */
50 12
    public function getColumnNames(): array
51
    {
52 12
        return $this->columnNames;
53
    }
54
55
    /**
56
     * @param string[] $columnNames
57
     * @return $this
58
     */
59 12
    public function setColumnNames(array $columnNames): self
60
    {
61 12
        $this->columnNames = $columnNames;
62 12
        return $this;
63
    }
64
}
65