Completed
Push — development ( ea08ae...a063ea )
by Volodymyr
15:59
created

AkeneoResourceCursor   A

Complexity

Total Complexity 7

Size/Duplication

Total Lines 67
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 15
dl 0
loc 67
rs 10
c 0
b 0
f 0
wmc 7

7 Methods

Rating   Name   Duplication   Size   Complexity  
A getPageSize() 0 4 1
A current() 0 4 1
A key() 0 4 1
A rewind() 0 4 1
A __construct() 0 3 1
A valid() 0 4 1
A next() 0 4 1
1
<?php
2
3
/**
4
 * MIT License
5
 * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
6
 */
7
8
namespace SprykerEco\Service\AkeneoPim\Dependencies\External\Api\Wrapper;
9
10
use Akeneo\Pim\ApiClient\Pagination\ResourceCursorInterface;
11
12
class AkeneoResourceCursor implements AkeneoResourceCursorInterface
13
{
14
    /**
15
     * @var \Akeneo\Pim\ApiClient\Pagination\ResourceCursorInterface
16
     */
17
    private $resourceCursor;
18
19
    /**
20
     * @param \Akeneo\Pim\ApiClient\Pagination\ResourceCursorInterface $resourceCursor
21
     */
22
    public function __construct(ResourceCursorInterface $resourceCursor)
23
    {
24
        $this->resourceCursor = $resourceCursor;
25
    }
26
27
    /**
28
     * {@inheritdoc}
29
     */
30
    public function getPageSize()
31
    {
32
        return $this->resourceCursor
33
            ->getPageSize();
34
    }
35
36
    /**
37
     * {@inheritdoc}
38
     */
39
    public function current()
40
    {
41
        return $this->resourceCursor
42
            ->current();
43
    }
44
45
    /**
46
     * {@inheritdoc}
47
     */
48
    public function next()
49
    {
50
        $this->resourceCursor
51
            ->next();
52
    }
53
54
    /**
55
     * {@inheritdoc}
56
     */
57
    public function key()
58
    {
59
        return $this->resourceCursor
60
            ->key();
61
    }
62
63
    /**
64
     * {@inheritdoc}
65
     */
66
    public function valid()
67
    {
68
        return $this->resourceCursor
69
            ->valid();
70
    }
71
72
    /**
73
     * {@inheritdoc}
74
     */
75
    public function rewind()
76
    {
77
        $this->resourceCursor
78
            ->rewind();
79
    }
80
}
81