Passed
Push — develop ( 6aacf8...6c0b7f )
by BENARD
11:52
created

LikeCountTrait::setLikeCount()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
c 1
b 0
f 0
dl 0
loc 5
rs 10
cc 1
nc 1
nop 1
1
<?php
2
3
namespace VideoGamesRecords\CoreBundle\Traits\Entity;
4
5
trait LikeCountTrait
6
{
7
    /**
8
     * @ORM\Column(name="likeCount", type="integer", nullable=false, options={"default":0})
9
     */
10
    private int $likeCount = 0;
11
12
    /**
13
     * Set likeCount
14
     *
15
     * @param integer $likeCount
16
     * @return $this
17
     */
18
    public function setLikeCount(int $likeCount): static
19
    {
20
        $this->likeCount = $likeCount;
21
22
        return $this;
23
    }
24
25
    /**
26
     * Get likeCount
27
     *
28
     * @return integer
29
     */
30
    public function getLikeCount(): int
31
    {
32
        return $this->likeCount;
33
    }
34
}
35