HasTemplateWithImmutablePagesSize   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 11
c 1
b 0
f 0
dl 0
loc 27
ccs 0
cts 10
cp 0
rs 10
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A setSize() 0 6 1
A setTemplatePageHeight() 0 5 1
A setTemplatePageWidth() 0 5 1
1
<?php
2
3
namespace LPDFBuilder\Generation;
4
5
trait HasTemplateWithImmutablePagesSize
6
{
7
    use HasTemplate;
8
9
    protected int $templatePageWidth  = 210;
10
    protected int $templatePageHeight = 297;
11
12
    public function setSize(int $templatePageWidth, int $templatePageHeight): static
13
    {
14
        $this->templatePageWidth  = $templatePageWidth;
15
        $this->templatePageHeight = $templatePageHeight;
16
17
        return $this;
18
    }
19
20
    public function setTemplatePageWidth(int $templatePageWidth): static
21
    {
22
        $this->templatePageWidth = $templatePageWidth;
23
24
        return $this;
25
    }
26
27
    public function setTemplatePageHeight(int $templatePageHeight): static
28
    {
29
        $this->templatePageHeight = $templatePageHeight;
30
31
        return $this;
32
    }
33
}
34