Completed
Push — master ( 6fb948...9654c5 )
by Marcus
08:56
created

Voucher::validate()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace MarcusJaschen\Collmex\Type;
6
7
/**
8
 * Voucher Type.
9
 *
10
 * @author   Marcus Jaschen <[email protected]>
11
 *
12
 * @property $type_identifier
13
 * @property $voucher_id
14
 * @property $client_id
15
 * @property $usage
16
 * @property $valid_from
17
 * @property $valid_to
18
 * @property $discount_percentage
19
 * @property $discount_total
20
 * @property $voucher_desc
21
 * @property $agent_id
22
 * @property $min_order_value
23
 * @property $currency
24
 */
25
class Voucher extends AbstractType implements TypeInterface
26
{
27
    /**
28
     * @var array
29
     */
30
    protected $template = [
31
        'type_identifier' => 'VOUCHER',
32
        'voucher_id' => null,
33
        'client_id' => null,
34
        'usage' => null,
35
        'valid_from' => null,
36
        'valid_to' => null,
37
        'discount_percentage' => null,
38
        'discount_total' => null,
39
        'voucher_desc' => null,
40
        'agent_id' => null,
41
        'min_order_value' => null,
42
        'currency' => null,
43
    ];
44
45
    /**
46
     * Formally validates the type data in $data attribute.
47
     *
48
     * @return bool Validation success
49
     */
50
    public function validate(): bool
51
    {
52
        return true;
53
    }
54
}
55