Completed
Push — master ( 175f05...5ac193 )
by Bukashk0zzz
04:34
created

OfferBook::setSeries()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 6
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 3
nc 1
nop 1
1
<?php
2
3
/*
4
 * This file is part of the Bukashk0zzzYmlGenerator
5
 *
6
 * (c) Denis Golubovskiy <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Bukashk0zzz\YmlGenerator\Model\Offer;
13
14
/**
15
 * Class OfferBook
16
 *
17
 * @author Denis Golubovskiy <[email protected]>
18
 */
19
class OfferBook extends AbstractOffer
20
{
21
    use OfferBookTrait;
22
23
    /**
24
     * @var string
25
     */
26
    private $binding;
27
28
    /**
29
     * @var int
30
     */
31
    private $pageExtent;
32
33
    /**
34
     * @return string
35
     */
36
    public function getType()
37
    {
38
        return 'book';
39
    }
40
41
    /**
42
     * @return string
43
     */
44
    public function getBinding()
45
    {
46
        return $this->binding;
47
    }
48
49
    /**
50
     * @param string $binding
51
     * @return $this
52
     */
53
    public function setBinding($binding)
54
    {
55
        $this->binding = $binding;
56
57
        return $this;
58
    }
59
60
    /**
61
     * @return int
62
     */
63
    public function getPageExtent()
64
    {
65
        return $this->pageExtent;
66
    }
67
68
    /**
69
     * @param int $pageExtent
70
     * @return $this
71
     */
72
    public function setPageExtent($pageExtent)
73
    {
74
        $this->pageExtent = $pageExtent;
75
76
        return $this;
77
    }
78
79
    /**
80
     * @return array
81
     */
82
    protected function getOptions()
83
    {
84
        return [
85
            'author' => $this->getAuthor(),
86
            'name' => $this->getName(),
87
            'publisher' => $this->getPublisher(),
88
            'series' => $this->getSeries(),
89
            'year' => $this->getYear(),
90
            'ISBN' => $this->getISBN(),
91
            'volume' => $this->getVolume(),
92
            'part' => $this->getPart(),
93
            'language' => $this->getLanguage(),
94
            'binding' => $this->getBinding(),
95
            'page_extent' => $this->getPageExtent(),
96
            'table_of_contents' => $this->getTableOfContents(),
97
        ];
98
    }
99
}
100