Passed
Pull Request — master (#4)
by Aleksey
09:30 queued 04:56
created

CrefoPayToOmsFacadeBridge   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
c 1
b 0
f 0
dl 0
loc 35
rs 10
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A checkConditions() 0 3 1
A __construct() 0 3 1
A triggerEventForOrderItems() 0 3 1
1
<?php
2
3
/**
4
 * MIT License
5
 * For full license information, please view the LICENSE file that was distributed with this source code.
6
 */
7
8
namespace SprykerEco\Zed\CrefoPay\Dependency\Facade;
9
10
class CrefoPayToOmsFacadeBridge implements CrefoPayToOmsFacadeInterface
11
{
12
    /**
13
     * @var \Spryker\Zed\Oms\Business\OmsFacadeInterface
14
     */
15
    protected $omsFacade;
16
17
    /**
18
     * @param \Spryker\Zed\Oms\Business\OmsFacadeInterface $omsFacade
19
     */
20
    public function __construct($omsFacade)
21
    {
22
        $this->omsFacade = $omsFacade;
23
    }
24
25
    /**
26
     * @param array $logContext
27
     *
28
     * @return int
29
     */
30
    public function checkConditions(array $logContext = [])
31
    {
32
        return $this->omsFacade->checkConditions($logContext);
33
    }
34
35
    /**
36
     * @param string $eventId
37
     * @param array $orderItemIds
38
     * @param array $data
39
     *
40
     * @return array|null
41
     */
42
    public function triggerEventForOrderItems($eventId, array $orderItemIds, array $data = [])
43
    {
44
        return $this->omsFacade->triggerEventForOrderItems($eventId, $orderItemIds, $data);
45
    }
46
}
47