RdvPointRetraitAcheminementResult   A
last analyzed

Complexity

Total Complexity 5

Size/Duplication

Total Lines 38
Duplicated Lines 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
wmc 5
eloc 9
c 2
b 0
f 0
dl 0
loc 38
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getRdv() 0 3 1
A __construct() 0 4 1
A setRdv() 0 8 3
1
<?php
2
3
namespace ColissimoPickupPoint\StructType;
4
5
use \WsdlToPhp\PackageBase\AbstractStructBase;
6
7
/**
8
 * This class stands for rdvPointRetraitAcheminementResult StructType
9
 * @subpackage Structs
10
 * @author WsdlToPhp <[email protected]>
11
 */
12
class RdvPointRetraitAcheminementResult extends PointRetraitAcheminementResult
13
{
14
    /**
15
     * The rdv
16
     * @var bool
17
     */
18
    public $rdv;
19
    /**
20
     * Constructor method for rdvPointRetraitAcheminementResult
21
     * @uses RdvPointRetraitAcheminementResult::setRdv()
22
     * @param bool $rdv
23
     */
24
    public function __construct($rdv = null)
25
    {
26
        $this
27
            ->setRdv($rdv);
28
    }
29
    /**
30
     * Get rdv value
31
     * @return bool|null
32
     */
33
    public function getRdv()
34
    {
35
        return $this->rdv;
36
    }
37
    /**
38
     * Set rdv value
39
     * @param bool $rdv
40
     * @return \ColissimoPickupPoint\StructType\RdvPointRetraitAcheminementResult
41
     */
42
    public function setRdv($rdv = null)
43
    {
44
        // validation for constraint: boolean
45
        if (!is_null($rdv) && !is_bool($rdv)) {
0 ignored issues
show
introduced by
The condition is_bool($rdv) is always true.
Loading history...
46
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a bool, %s given', var_export($rdv, true), gettype($rdv)), __LINE__);
47
        }
48
        $this->rdv = $rdv;
49
        return $this;
50
    }
51
}
52