Passed
Push — master ( 022b32...35c6c5 )
by Aleksandr
01:52
created

Driver::getHeader()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
ccs 0
cts 2
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * This file is part of the eav package.
4
 * @author    Aleksandr Drobotik <[email protected]>
5
 * @copyright 2023 Aleksandr Drobotik
6
 * @license   https://opensource.org/license/mit  The MIT License
7
 */
8
declare(strict_types=1);
9
10
namespace Drobotik\Eav;
11
12
use Drobotik\Eav\Interfaces\DriverInterface;
0 ignored issues
show
Bug introduced by
The type Drobotik\Eav\Interfaces\DriverInterface was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
13
14
abstract class Driver implements DriverInterface
15
{
16
    private int $total;
17
    private int $cursor;
18
    private int $chunkSize;
19
    protected array $header;
20
21
    public function getChunkSize() : int
22
    {
23
        return $this->chunkSize;
24
    }
25
26
    public function setChunkSize(int $size)
27
    {
28
        $this->chunkSize = $size;
29
    }
30
31
    public function getCursor() : int
32
    {
33
        return $this->cursor;
34
    }
35
36
    public function setCursor(int $cursor) : void
37
    {
38
        $this->cursor = $cursor;
39
    }
40
41
    public function setTotal(int $total)
42
    {
43
        $this->total = $total;
44
    }
45
46
    public function getTotal() : int
47
    {
48
        return $this->total;
49
    }
50
51
    public function getHeader(): array
52
    {
53
        return $this->header;
54
    }
55
56
    public function setHeader(array $columns): void
57
    {
58
        $this->header = $columns;
59
    }
60
61
    public function isHeader(): bool
62
    {
63
        return isset($this->header);
64
    }
65
66
}