Passed
Push — master ( c03365...9d1091 )
by Alex
07:25
created

TDesignerPropertyType::setValue()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace AlgoWeb\ODataMetadata\MetadataV3\edmx;
4
5
/**
6
 * Class representing TDesignerPropertyType
7
 *
8
 *
9
 * XSD Type: TDesignerProperty
10
 */
11
class TDesignerPropertyType
12
{
13
14
    /**
15
     * @property string $name
16
     */
17
    private $name = null;
18
19
    /**
20
     * @property string $value
21
     */
22
    private $value = null;
23
24
    /**
25
     * Gets as name
26
     *
27
     * @return string
28
     */
29
    public function getName()
30
    {
31
        return $this->name;
32
    }
33
34
    /**
35
     * Sets a new name
36
     *
37
     * @param string $name
38
     * @return self
39
     */
40
    public function setName($name)
41
    {
42
        $this->name = $name;
43
        return $this;
44
    }
45
46
    /**
47
     * Gets as value
48
     *
49
     * @return string
50
     */
51
    public function getValue()
52
    {
53
        return $this->value;
54
    }
55
56
    /**
57
     * Sets a new value
58
     *
59
     * @param string $value
60
     * @return self
61
     */
62
    public function setValue($value)
63
    {
64
        $this->value = $value;
65
        return $this;
66
    }
67
68
    public function isOK()
69
    {
70
        if (null == $this->name) {
71
            return false;
72
        }
73
        if (null == $this->value) {
74
            return false;
75
        }
76
        return true;
77
    }
78
}
79