TaxAppDependencyProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 11
dl 0
loc 29
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getFallbackOrderCalculationPlugins() 0 7 1
A getFallbackQuoteCalculationPlugins() 0 7 1
1
<?php
2
3
/**
4
 * This file is part of the Spryker Commerce OS.
5
 * For full license information, please view the LICENSE file that was distributed with this source code.
6
 */
7
8
declare(strict_types = 1);
9
10
namespace Pyz\Zed\TaxApp;
11
12
use Spryker\Zed\Calculation\Communication\Plugin\Calculator\ItemTaxAmountFullAggregatorPlugin;
13
use Spryker\Zed\Calculation\Communication\Plugin\Calculator\PriceToPayAggregatorPlugin;
14
use Spryker\Zed\Tax\Communication\Plugin\Calculator\TaxAmountAfterCancellationCalculatorPlugin;
15
use Spryker\Zed\Tax\Communication\Plugin\Calculator\TaxAmountCalculatorPlugin;
16
use Spryker\Zed\Tax\Communication\Plugin\Calculator\TaxRateAverageAggregatorPlugin;
17
use Spryker\Zed\TaxApp\TaxAppDependencyProvider as SprykerTaxAppDependencyProvider;
18
19
class TaxAppDependencyProvider extends SprykerTaxAppDependencyProvider
20
{
21
    /**
22
     * {@inheritDoc}
23
     *
24
     * @return array<\Spryker\Zed\CalculationExtension\Dependency\Plugin\CalculationPluginInterface>
25
     */
26
    protected function getFallbackQuoteCalculationPlugins(): array
27
    {
28
        return [
29
            new TaxAmountCalculatorPlugin(),
30
            new ItemTaxAmountFullAggregatorPlugin(),
31
            new PriceToPayAggregatorPlugin(),
32
            new TaxRateAverageAggregatorPlugin(),
33
        ];
34
    }
35
36
    /**
37
     * {@inheritDoc}
38
     *
39
     * @return array<\Spryker\Zed\CalculationExtension\Dependency\Plugin\CalculationPluginInterface>
40
     */
41
    protected function getFallbackOrderCalculationPlugins(): array
42
    {
43
        return [
44
            new TaxAmountCalculatorPlugin(),
45
            new ItemTaxAmountFullAggregatorPlugin(),
46
            new PriceToPayAggregatorPlugin(),
47
            new TaxAmountAfterCancellationCalculatorPlugin(),
48
        ];
49
    }
50
}
51