CustomFieldModel::getId()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 4
Ratio 100 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 4
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
/*
4
 * This file is part of the zibios/wrike-php-jmsserializer package.
5
 *
6
 * (c) Zbigniew Ślązak
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Zibios\WrikePhpJmsserializer\Model\Common;
13
14
use JMS\Serializer\Annotation as SA;
15
use Zibios\WrikePhpJmsserializer\Model\AbstractModel;
16
use Zibios\WrikePhpJmsserializer\Model\ResourceModelInterface;
17
18
/**
19
 * Custom Field Model.
20
 */
21 View Code Duplication
class CustomFieldModel extends AbstractModel implements ResourceModelInterface
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
22
{
23
    /**
24
     * Custom Field ID.
25
     *
26
     * @SA\Type("string")
27
     * @SA\SerializedName("id")
28
     *
29
     * @var string|null
30
     */
31
    protected $id;
32
33
    /**
34
     * Custom field value.
35
     *
36
     * @SA\Type("string")
37
     * @SA\SerializedName("value")
38
     *
39
     * @var string|null
40
     */
41
    protected $value;
42
43
    /**
44
     * @return null|string
45
     */
46 1
    public function getId()
47
    {
48 1
        return $this->id;
49
    }
50
51
    /**
52
     * @param null|string $id
53
     *
54
     * @return $this
55
     */
56 1
    public function setId($id)
57
    {
58 1
        $this->id = $id;
59
60 1
        return $this;
61
    }
62
63
    /**
64
     * @return null|string
65
     */
66 1
    public function getValue()
67
    {
68 1
        return $this->value;
69
    }
70
71
    /**
72
     * @param null|string $value
73
     *
74
     * @return $this
75
     */
76 1
    public function setValue($value)
77
    {
78 1
        $this->value = $value;
79
80 1
        return $this;
81
    }
82
}
83