Passed
Branch request_builder (c1031c)
by Jens
08:30
created

CartDiscountsActionBuilder   A

Complexity

Total Complexity 11

Size/Duplication

Total Lines 88
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 11
dl 0
loc 88
ccs 22
cts 22
cp 1
rs 10
c 0
b 0
f 0

11 Methods

Rating   Name   Duplication   Size   Complexity  
A changeIsActive() 0 3 1
A changeSortOrder() 0 3 1
A setValidUntil() 0 3 1
A changeRequiresDiscountCode() 0 3 1
A setDescription() 0 3 1
A changeTarget() 0 3 1
A changeCartPredicate() 0 3 1
A changeName() 0 3 1
A changeStackingMode() 0 3 1
A changeValue() 0 3 1
A setValidFrom() 0 3 1
1
<?php
2
3
namespace Commercetools\Core\Builder\Update;
4
5
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeNameAction;
6
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeStackingModeAction;
7
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeCartPredicateAction;
8
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeRequiresDiscountCodeAction;
9
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountSetValidUntilAction;
10
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountSetDescriptionAction;
11
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeSortOrderAction;
12
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountSetValidFromAction;
13
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeIsActiveAction;
14
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeValueAction;
15
use Commercetools\Core\Request\CartDiscounts\Command\CartDiscountChangeTargetAction;
16
17
class CartDiscountsActionBuilder
18
{
19
    /**
20
     * @return CartDiscountChangeNameAction
21
     */
22 1
    public function changeName()
23
    {
24 1
        return CartDiscountChangeNameAction::of();
25
    }
26
27
    /**
28
     * @return CartDiscountChangeStackingModeAction
29
     */
30 1
    public function changeStackingMode()
31
    {
32 1
        return CartDiscountChangeStackingModeAction::of();
33
    }
34
35
    /**
36
     * @return CartDiscountChangeCartPredicateAction
37
     */
38 1
    public function changeCartPredicate()
39
    {
40 1
        return CartDiscountChangeCartPredicateAction::of();
41
    }
42
43
    /**
44
     * @return CartDiscountChangeRequiresDiscountCodeAction
45
     */
46 1
    public function changeRequiresDiscountCode()
47
    {
48 1
        return CartDiscountChangeRequiresDiscountCodeAction::of();
49
    }
50
51
    /**
52
     * @return CartDiscountSetValidUntilAction
53
     */
54 1
    public function setValidUntil()
55
    {
56 1
        return CartDiscountSetValidUntilAction::of();
57
    }
58
59
    /**
60
     * @return CartDiscountSetDescriptionAction
61
     */
62 1
    public function setDescription()
63
    {
64 1
        return CartDiscountSetDescriptionAction::of();
65
    }
66
67
    /**
68
     * @return CartDiscountChangeSortOrderAction
69
     */
70 1
    public function changeSortOrder()
71
    {
72 1
        return CartDiscountChangeSortOrderAction::of();
73
    }
74
75
    /**
76
     * @return CartDiscountSetValidFromAction
77
     */
78 1
    public function setValidFrom()
79
    {
80 1
        return CartDiscountSetValidFromAction::of();
81
    }
82
83
    /**
84
     * @return CartDiscountChangeIsActiveAction
85
     */
86 1
    public function changeIsActive()
87
    {
88 1
        return CartDiscountChangeIsActiveAction::of();
89
    }
90
91
    /**
92
     * @return CartDiscountChangeValueAction
93
     */
94 1
    public function changeValue()
95
    {
96 1
        return CartDiscountChangeValueAction::of();
97
    }
98
99
    /**
100
     * @return CartDiscountChangeTargetAction
101
     */
102 1
    public function changeTarget()
103
    {
104 1
        return CartDiscountChangeTargetAction::of();
105
    }
106
}
107