Passed
Push — master ( fd93b5...48e916 )
by Doug
40:26 queued 29:39
created

IGNFHeightGrid::getValues()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 2
dl 0
loc 5
ccs 0
cts 3
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * PHPCoord.
4
 *
5
 * @author Doug Wright
6
 */
7
declare(strict_types=1);
8
9
namespace PHPCoord\CoordinateOperation;
10
11
use PHPCoord\UnitOfMeasure\Length\Metre;
12
13
class IGNFHeightGrid extends GeographicGeoidHeightGrid
14
{
15
    use IGNFGrid;
16
17
    /**
18
     * @return Metre[]
19
     */
20
    public function getValues(float $x, float $y): array
21
    {
22
        $shift = $this->interpolate($x, $y)[0];
23
24
        return [new Metre($shift)];
25
    }
26
}
27