Passed
Push — ref ( 45b89b )
by Asmir
02:50
created

FaultCode   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 47
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 6
eloc 8
c 1
b 0
f 0
dl 0
loc 47
rs 10

5 Methods

Rating   Name   Duplication   Size   Complexity  
A getValue() 0 3 1
A setSubcode() 0 3 1
A __toString() 0 3 2
A getSubcode() 0 3 1
A setValue() 0 3 1
1
<?php
2
3
namespace GoetasWebservices\SoapServices\Metadata\Envelope\SoapEnvelope12\Parts;
4
5
class FaultCode
6
{
7
    /**
8
     * @var string
9
     */
10
    private $value;
11
12
    /**
13
     * @var FaultCode
14
     */
15
    private $subcode;
16
17
    /**
18
     * @return string
19
     */
20
    public function getValue()
21
    {
22
        return $this->value;
23
    }
24
25
    /**
26
     * @param string $value
27
     */
28
    public function setValue($value)
29
    {
30
        $this->value = $value;
31
    }
32
33
    /**
34
     * @return FaultCode
35
     */
36
    public function getSubcode()
37
    {
38
        return $this->subcode;
39
    }
40
41
    /**
42
     * @param FaultCode $subcode
43
     */
44
    public function setSubcode(FaultCode $subcode)
45
    {
46
        $this->subcode = $subcode;
47
    }
48
49
    public function __toString()
50
    {
51
        return $this->value . ($this->subcode ? (":" . $this->subcode) : "");
52
    }
53
}
54
55