RoundedShape::getCenterY()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
namespace nstdio\svg\shape;
3
4
5
6
use nstdio\svg\ElementInterface;
7
8
/**
9
 * Class RoundedShape
10
 * @property float $cx The capacitor for x axis
11
 * @property float $cy The capacitor for y axis
12
 * @package shape
13
 * @author  Edgar Asatryan <[email protected]>
14
 */
15
abstract class RoundedShape extends Shape
16
{
17 26
    public function __construct(ElementInterface $parent, $cx, $cy)
18
    {
19 26
        parent::__construct($parent);
20
21 26
        $this->cx = $cx;
22 26
        $this->cy = $cy;
23 26
    }
24
25 1
    protected function getCenterX()
26
    {
27 1
        return $this->cx;
28
    }
29
30 1
    protected function getCenterY()
31
    {
32 1
        return $this->cy;
33
    }
34
}