Completed
Push — master ( 1ed55c...1adee7 )
by Giancarlos
03:47
created

Shipment::setModTraslado()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 5
ccs 3
cts 3
cp 1
rs 9.4285
cc 1
eloc 3
nc 1
nop 1
crap 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: Giansalex
5
 * Date: 08/08/2017
6
 * Time: 00:03
7
 */
8
9
namespace Greenter\Model\Despatch;
10
use Greenter\Xml\Validator\ShipmentValidator;
11
use Symfony\Component\Validator\Constraints as Assert;
12
13
/**
14
 * Class Shipment
15
 * @package Greenter\Model\Despatch
16
 */
17
class Shipment
18
{
19
    use ShipmentValidator;
20
21
    /**
22
     * Motivo del traslado
23
     *
24
     * @Assert\NotBlank()
25
     * @Assert\Length(min="2", max="2")
26
     * @var string
27
     */
28
    private $codTraslado;
29
30
    /**
31
     * Descripción de motivo de traslado
32
     *
33
     * @Assert\Length(max="100")
34
     * @var string
35
     */
36
    private $desTraslado;
37
38
    /**
39
     * Indicador de Transbordo Programado.
40
     *
41
     * @Assert\NotBlank()
42
     * @var bool
43
     */
44
    private $indTransbordo;
45
46
    /**
47
     * @Assert\NotBlank()
48
     * @var float
49
     */
50
    private $pesoTotal;
51
52
    /**
53
     * @Assert\NotBlank()
54
     * @Assert\Length(max="4")
55
     * @var string
56
     */
57
    private $undPesoTotal;
58
59
    /**
60
     * Numero de Bultos.
61
     *
62
     * @var int
63
     */
64
    private $numBultos;
65
66
    /**
67
     * @Assert\NotBlank()
68
     * @Assert\Length(min="2", max="2")
69
     * @var string
70
     */
71
    private $modTraslado;
72
73
    /**
74
     * Fecha de inicio del traslado
75
     *
76
     * @Assert\NotBlank()
77
     * @Assert\Date()
78
     * @var \DateTime
79
     */
80
    private $fecTraslado;
81
82
    /**
83
     * Numero de Contenedor (Motivo Importación)
84
     *
85
     * @Assert\Length(max="17")
86
     * @var string
87
     */
88
    private $numContenedor;
89
90
    /**
91
     * Codigo del Puerto. (Puerto o Aeropuerto de embarque/desembarque)
92
     *
93
     * @Assert\Length(max="3")
94
     * @var string
95
     */
96
    private $codPuerto;
97
98
    /**
99
     * @Assert\Valid()
100
     * @var Transportist
101
     */
102
    private $transportista;
103
104
    /**
105
     * @Assert\Valid()
106
     * @var Direction
107
     */
108
    private $llegada;
109
110
    /**
111
     * @Assert\Valid()
112
     * @var Direction
113
     */
114
    private $partida;
115
116
    /**
117
     * @return string
118
     */
119 2
    public function getCodTraslado()
120
    {
121 2
        return $this->codTraslado;
122
    }
123
124
    /**
125
     * @param string $codTraslado
126
     * @return Shipment
127
     */
128 6
    public function setCodTraslado($codTraslado)
129
    {
130 6
        $this->codTraslado = $codTraslado;
131 6
        return $this;
132
    }
133
134
    /**
135
     * @return string
136
     */
137 2
    public function getDesTraslado()
138
    {
139 2
        return $this->desTraslado;
140
    }
141
142
    /**
143
     * @param string $desTraslado
144
     * @return Shipment
145
     */
146 6
    public function setDesTraslado($desTraslado)
147
    {
148 6
        $this->desTraslado = $desTraslado;
149 6
        return $this;
150
    }
151
152
    /**
153
     * @return bool
154
     */
155 2
    public function isIndTransbordo()
156
    {
157 2
        return $this->indTransbordo;
158
    }
159
160
    /**
161
     * @param bool $indTransbordo
162
     * @return Shipment
163
     */
164 6
    public function setIndTransbordo($indTransbordo)
165
    {
166 6
        $this->indTransbordo = $indTransbordo;
167 6
        return $this;
168
    }
169
170
    /**
171
     * @return float
172
     */
173 2
    public function getPesoTotal()
174
    {
175 2
        return $this->pesoTotal;
176
    }
177
178
    /**
179
     * @param float $pesoTotal
180
     * @return Shipment
181
     */
182 6
    public function setPesoTotal($pesoTotal)
183
    {
184 6
        $this->pesoTotal = $pesoTotal;
185 6
        return $this;
186
    }
187
188
    /**
189
     * @return string
190
     */
191 2
    public function getUndPesoTotal()
192
    {
193 2
        return $this->undPesoTotal;
194
    }
195
196
    /**
197
     * @param string $undPesoTotal
198
     * @return Shipment
199
     */
200 6
    public function setUndPesoTotal($undPesoTotal)
201
    {
202 6
        $this->undPesoTotal = $undPesoTotal;
203 6
        return $this;
204
    }
205
206
    /**
207
     * @return int
208
     */
209 2
    public function getNumBultos()
210
    {
211 2
        return $this->numBultos;
212
    }
213
214
    /**
215
     * @param int $numBultos
216
     * @return Shipment
217
     */
218 6
    public function setNumBultos($numBultos)
219
    {
220 6
        $this->numBultos = $numBultos;
221 6
        return $this;
222
    }
223
224
    /**
225
     * @return string
226
     */
227 2
    public function getModTraslado()
228
    {
229 2
        return $this->modTraslado;
230
    }
231
232
    /**
233
     * @param string $modTraslado
234
     * @return Shipment
235
     */
236 6
    public function setModTraslado($modTraslado)
237
    {
238 6
        $this->modTraslado = $modTraslado;
239 6
        return $this;
240
    }
241
242
    /**
243
     * @return \DateTime
244
     */
245 2
    public function getFecTraslado()
246
    {
247 2
        return $this->fecTraslado;
248
    }
249
250
    /**
251
     * @param \DateTime $fecTraslado
252
     * @return Shipment
253
     */
254 6
    public function setFecTraslado($fecTraslado)
255
    {
256 6
        $this->fecTraslado = $fecTraslado;
257 6
        return $this;
258
    }
259
260
    /**
261
     * @return string
262
     */
263 2
    public function getNumContenedor()
264
    {
265 2
        return $this->numContenedor;
266
    }
267
268
    /**
269
     * @param string $numContenedor
270
     * @return Shipment
271
     */
272 6
    public function setNumContenedor($numContenedor)
273
    {
274 6
        $this->numContenedor = $numContenedor;
275 6
        return $this;
276
    }
277
278
    /**
279
     * @return string
280
     */
281 2
    public function getCodPuerto()
282
    {
283 2
        return $this->codPuerto;
284
    }
285
286
    /**
287
     * @param string $codPuerto
288
     * @return Shipment
289
     */
290 6
    public function setCodPuerto($codPuerto)
291
    {
292 6
        $this->codPuerto = $codPuerto;
293 6
        return $this;
294
    }
295
296
    /**
297
     * @return Transportist
298
     */
299 2
    public function getTransportista()
300
    {
301 2
        return $this->transportista;
302
    }
303
304
    /**
305
     * @param Transportist $transportista
306
     * @return Shipment
307
     */
308 6
    public function setTransportista($transportista)
309
    {
310 6
        $this->transportista = $transportista;
311 6
        return $this;
312
    }
313
314
    /**
315
     * @return Direction
316
     */
317 2
    public function getLlegada()
318
    {
319 2
        return $this->llegada;
320
    }
321
322
    /**
323
     * @param Direction $llegada
324
     * @return Shipment
325
     */
326 6
    public function setLlegada($llegada)
327
    {
328 6
        $this->llegada = $llegada;
329 6
        return $this;
330
    }
331
332
    /**
333
     * @return Direction
334
     */
335 2
    public function getPartida()
336
    {
337 2
        return $this->partida;
338
    }
339
340
    /**
341
     * @param Direction $partida
342
     * @return Shipment
343
     */
344 6
    public function setPartida($partida)
345
    {
346 6
        $this->partida = $partida;
347 6
        return $this;
348
    }
349
}