Test Failed
Push — master ( b856ab...dd13ee )
by Jan
01:53
created

ResizableTrait::setHeight()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 2
c 0
b 0
f 0
dl 0
loc 5
rs 10
cc 1
nc 1
nop 1
1
<?php
2
declare(strict_types=1);
3
4
namespace DiscordWebhook\Embed\Traits;
5
6
/**
7
 * Trait ResizableTrait
8
 *
9
 * @package DiscordWebhook\Embed\Traits
10
 * @author Scrummer <[email protected]>
11
 */
12
trait ResizableTrait
13
{
14
    /**
15
     * @var int|null
16
     */
17
    private $width;
18
19
    /**
20
     * @var int|null
21
     */
22
    private $height;
23
24
    /**
25
     * @return int|null
26
     */
27
    public function getWidth(): ?int
28
    {
29
        return $this->width;
30
    }
31
32
    /**
33
     * @param int|null $width
34
     *
35
     * @return self
36
     */
37
    public function setWidth(?int $width): self
38
    {
39
        $this->width = $width;
40
41
        return $this;
42
    }
43
44
    /**
45
     * @return int|null
46
     */
47
    public function getHeight(): ?int
48
    {
49
        return $this->height;
50
    }
51
52
    /**
53
     * @param int|null $height
54
     *
55
     * @return self
56
     */
57
    public function setHeight(?int $height): self
58
    {
59
        $this->height = $height;
60
61
        return $this;
62
    }
63
}
64