Completed
Push — master ( 544fde...527d7b )
by Giancarlos
02:31
created

Voided   A

Complexity

Total Complexity 9

Size/Duplication

Total Lines 101
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 9
lcom 0
cbo 1
dl 0
loc 101
ccs 0
cts 37
cp 0
rs 10
c 0
b 0
f 0

9 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getCorrelativo() 0 4 1
A setCorrelativo() 0 5 1
A getFecGeneracion() 0 4 1
A setFecGeneracion() 0 4 1
A getFecComunicacion() 0 4 1
A setFecComunicacion() 0 4 1
A getDetails() 0 4 1
A setDetails() 0 4 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: Giansalex
5
 * Date: 15/07/2017
6
 * Time: 22:00
7
 */
8
9
namespace Greenter\Xml\Model\Voided;
10
11
use Greenter\Xml\Validator\VoidedValidator;
12
use Symfony\Component\Validator\Constraints as Assert;
13
14
/**
15
 * Class Voided
16
 * @package Greenter\Xml\Model\Voided
17
 */
18
class Voided
19
{
20
    use VoidedValidator;
21
22
    /**
23
     * @Assert\NotBlank()
24
     * @Assert\Length(max="3")
25
     * @var string
26
     */
27
    private $correlativo;
28
29
    /**
30
     * @Assert\Date()
31
     * @var \DateTime
32
     */
33
    private $fecGeneracion;
34
35
    /**
36
     * @Assert\NotBlank()
37
     * @Assert\Date()
38
     * @var \DateTime
39
     */
40
    private $fecComunicacion;
41
42
    /**
43
     * @Assert\Valid()
44
     * @var VoidedDetail[]
45
     */
46
    private $details;
47
48
    public function __construct()
49
    {
50
        $this->fecGeneracion = new \DateTime();
51
    }
52
53
    /**
54
     * @return string
55
     */
56
    public function getCorrelativo()
57
    {
58
        return $this->correlativo;
59
    }
60
61
    /**
62
     * @param string $correlativo
63
     * @return Voided
64
     */
65
    public function setCorrelativo($correlativo)
66
    {
67
        $this->correlativo = $correlativo;
68
        return $this;
69
    }
70
71
    /**
72
     * @return \DateTime
73
     */
74
    public function getFecGeneracion()
75
    {
76
        return $this->fecGeneracion;
77
    }
78
79
    /**
80
     * @param \DateTime $fecGeneracion
81
     */
82
    public function setFecGeneracion($fecGeneracion)
83
    {
84
        $this->fecGeneracion = $fecGeneracion;
85
    }
86
87
    /**
88
     * @return \DateTime
89
     */
90
    public function getFecComunicacion()
91
    {
92
        return $this->fecComunicacion;
93
    }
94
95
    /**
96
     * @param \DateTime $fecComunicacion
97
     */
98
    public function setFecComunicacion($fecComunicacion)
99
    {
100
        $this->fecComunicacion = $fecComunicacion;
101
    }
102
103
    /**
104
     * @return VoidedDetail[]
105
     */
106
    public function getDetails()
107
    {
108
        return $this->details;
109
    }
110
111
    /**
112
     * @param VoidedDetail[] $details
113
     */
114
    public function setDetails($details)
115
    {
116
        $this->details = $details;
117
    }
118
}