PaginatedCollection::getLimit()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 1
b 0
f 0
1
<?php
2
3
namespace Blackmine\Collection;
4
5
class PaginatedCollection extends IdentityCollection
6
{
7
    protected int $limit;
8
    protected int $total_count;
9
    protected int $offset;
10
11
    /**
12
     * @return int
13
     */
14
    public function getLimit(): int
15
    {
16
        return $this->limit;
17
    }
18
19
    /**
20
     * @param int|null $limit
21
     */
22
    public function setLimit(?int $limit): void
23
    {
24
        $this->limit = $limit;
25
    }
26
27
    /**
28
     * @return int
29
     */
30
    public function getTotalCount(): int
31
    {
32
        return $this->total_count;
33
    }
34
35
    /**
36
     * @param int|null $total_count
37
     */
38
    public function setTotalCount(?int $total_count): void
39
    {
40
        $this->total_count = $total_count;
41
    }
42
43
    /**
44
     * @return int
45
     */
46
    public function getOffset(): int
47
    {
48
        return $this->offset;
49
    }
50
51
    /**
52
     * @param int|null $offset
53
     */
54
    public function setOffset(?int $offset): void
55
    {
56
        $this->offset = $offset;
57
    }
58
}
59