AnotherPage::fillInputs()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 4
ccs 3
cts 3
cp 1
crap 1
rs 10
1
<?php
2
3
namespace kalanis\kw_paging\Render\SimplifiedPager;
4
5
6
use kalanis\kw_paging\Interfaces\ILink;
7
use kalanis\kw_templates\ATemplate;
8
use kalanis\kw_templates\Template\TFile;
9
10
11
class AnotherPage extends ATemplate
12
{
13
    use TFile;
14
15 5
    protected function templatePath(): string
16
    {
17 5
        return __DIR__ . '/Templates/AnotherPage.phtml';
18
    }
19
20 5
    protected function fillInputs(): void
21
    {
22 5
        $this->addInput('{PAGE_URL}');
23 5
        $this->addInput('{PAGE_NUMBER}');
24 5
    }
25
26 5
    public function setData(ILink $link, string $pageNumber): self
27
    {
28 5
        $this->updateItem('{PAGE_URL}', $link->getPageLink());
29 5
        $this->updateItem('{PAGE_NUMBER}', $pageNumber);
30 5
        return $this;
31
    }
32
}
33