Completed
Pull Request — 2.10 (#3834)
by Máté
12:16
created

View::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1.0156

Importance

Changes 0
Metric Value
eloc 2
dl 0
loc 4
ccs 3
cts 4
cp 0.75
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
crap 1.0156
1
<?php
2
3
namespace Doctrine\DBAL\Schema;
4
5
/**
6
 * Representation of a Database View.
7
 */
8
class View extends AbstractAsset
9
{
10
    /** @var string */
11
    private $sql;
12
13
    /**
14
     * @param string $name
15
     * @param string $sql
16
     */
17 33
    public function __construct($name, $sql)
18
    {
19 33
        $this->_setName($name);
20 33
        $this->sql = $sql;
21 33
    }
22
23
    /**
24
     * @return string
25
     */
26 33
    public function getSql()
27
    {
28 33
        return $this->sql;
29
    }
30
}
31