Completed
Push — master ( caad37...82c5ce )
by Dmitriy
06:13
created

Offer   A

Complexity

Total Complexity 24

Size/Duplication

Total Lines 310
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 87.5%

Importance

Changes 2
Bugs 0 Features 1
Metric Value
wmc 24
c 2
b 0
f 1
lcom 0
cbo 1
dl 0
loc 310
ccs 42
cts 48
cp 0.875
rs 10

24 Methods

Rating   Name   Duplication   Size   Complexity  
A getId() 0 4 1
A getModelId() 0 4 1
A getCategoryId() 0 4 1
A getVendorId() 0 4 1
A getCpa() 0 4 1
A getName() 0 4 1
A getVariationsCount() 0 4 1
A getDescription() 0 4 1
A getShopInfo() 0 4 1
A getOnStock() 0 4 1
A getWarranty() 0 4 1
A getUrl() 0 4 1
A getPrice() 0 4 1
A getPhone() 0 4 1
A getDelivery() 0 4 1
A getPhotos() 0 4 1
A getPreviewPhotos() 0 4 1
A getBigPhoto() 0 4 1
A getOutlet() 0 4 1
A getOutletCount() 0 4 1
A getWarning() 0 4 1
A getAge() 0 4 1
A getVendor() 0 4 1
A getFilters() 0 4 1
1
<?php
2
3
namespace Yandex\Market\Content\Models;
4
5
use Yandex\Common\Model;
6
7
class Offer extends Model
8
{
9
    protected $id = null;
10
11
    protected $modelId = null;
12
13
    protected $categoryId = null;
14
15
    protected $vendorId = null;
16
17
    protected $cpa = null;
18
19
    protected $name = null;
20
21
    protected $variationsCount = null;
22
23
    protected $description = null;
24
25
    protected $shopInfo = null;
26
27
    protected $onStock = null;
28
29
    protected $warranty = null;
30
31
    protected $url = null;
32
33
    protected $price = null;
34
35
    protected $phone = null;
36
37
    protected $delivery = null;
38
39
    protected $photos = null;
40
41
    protected $previewPhotos = null;
42
43
    protected $bigPhoto = null;
44
45
    protected $outlet = null;
46
47
    protected $outletCount = null;
48
49
    protected $warning = null;
50
51
    protected $age = null;
52
53
    protected $vendor = null;
54
55
    protected $filters = null;
56
57
    protected $mappingClasses = [
58
        'shopInfo' => 'Yandex\Market\Content\Models\ShopInfo',
59
        'photos' => 'Yandex\Market\Content\Models\OfferPhotos',
60
        'previewPhotos' => 'Yandex\Market\Content\Models\OfferPhotos',
61
        'bigPhoto' => 'Yandex\Market\Content\Models\OfferPhoto',
62
        'price' => 'Yandex\Market\Content\Models\Base\Price',
63
        'phone' => 'Yandex\Market\Content\Models\Phone',
64
        'delivery' => 'Yandex\Market\Content\Models\Delivery',
65
        'outlet' => 'Yandex\Market\Content\Models\Outlet',
66
        'filters' => 'Yandex\Market\Content\Models\Filters',
67
        'vendor' =>  'Yandex\Market\Content\Models\Vendor'
68
    ];
69
70
    protected $propNameMap = [
71
        'offerId' => 'id',
72
        'variations' => 'variationsCount'
73
    ];
74
75
    /**
76
     * Retrieve the id property
77
     *
78
     * @return string|null
79
     */
80 6
    public function getId()
81
    {
82 6
        return $this->id;
83
    }
84
85
    /**
86
     * Retrieve the modelId property
87
     *
88
     * @return int|null
89
     */
90 3
    public function getModelId()
91
    {
92 3
        return $this->modelId;
93
    }
94
95
    /**
96
     * Retrieve the categoryId property
97
     *
98
     * @return int|null
99
     */
100 4
    public function getCategoryId()
101
    {
102 4
        return $this->categoryId;
103
    }
104
105
    /**
106
     * Retrieve the vemdorId property
107
     *
108
     * @return int|null
109
     */
110 4
    public function getVendorId()
111
    {
112 4
        return $this->vendorId;
113
    }
114
115
    /**
116
     * Retrieve the cpa property
117
     *
118
     * @return int|null
119
     */
120 1
    public function getCpa()
121
    {
122 1
        return $this->cpa;
123
    }
124
125
    /**
126
     * Retrieve the name property
127
     *
128
     * @return string|null
129
     */
130 5
    public function getName()
131
    {
132 5
        return $this->name;
133
    }
134
135
    /**
136
     * Retrieve the variationsCount property
137
     *
138
     * @return int|null
139
     */
140 1
    public function getVariationsCount()
141
    {
142 1
        return $this->variationsCount;
143
    }
144
145
    /**
146
     * Retrieve the description property
147
     *
148
     * @return string|null
149
     */
150 2
    public function getDescription()
151
    {
152 2
        return $this->description;
153
    }
154
155
    /**
156
     * Retrieve the shopInfo property
157
     *
158
     * @return ShopInfo|null
159
     */
160 5
    public function getShopInfo()
161
    {
162 5
        return $this->shopInfo;
163
    }
164
165
    /**
166
     * Retrieve the onStock property
167
     *
168
     * @return int|null
169
     */
170 5
    public function getOnStock()
171
    {
172 5
        return $this->onStock;
173
    }
174
175
    /**
176
     * Retrieve the warranty property
177
     *
178
     * @return int|null
179
     */
180 4
    public function getWarranty()
181
    {
182 4
        return $this->warranty;
183
    }
184
185
    /**
186
     * Retrieve the url property
187
     *
188
     * @return string|null
189
     */
190 5
    public function getUrl()
191
    {
192 5
        return $this->url;
193
    }
194
195
    /**
196
     * Retrieve the price property
197
     *
198
     * @return Price|null
199
     */
200 5
    public function getPrice()
201
    {
202 5
        return $this->price;
203
    }
204
205
    /**
206
     * Retrieve the phone property
207
     *
208
     * @return Phone|null
209
     */
210 5
    public function getPhone()
211
    {
212 5
        return $this->phone;
213
    }
214
215
    /**
216
     * Retrieve the delivery property
217
     *
218
     * @return Delivery|null
219
     */
220 5
    public function getDelivery()
221
    {
222 5
        return $this->delivery;
223
    }
224
225
    /**
226
     * Retrieve the photos property
227
     *
228
     * @return Photos|null
229
     */
230 4
    public function getPhotos()
231
    {
232 4
        return $this->photos;
233
    }
234
235
    /**
236
     * Retrieve the previewPhotos property
237
     *
238
     * @return Photos|null
239
     */
240 4
    public function getPreviewPhotos()
241
    {
242 4
        return $this->previewPhotos;
243
    }
244
245
    /**
246
     * Retrieve the bigPhoto property
247
     *
248
     * @return Photo|null
249
     */
250 5
    public function getBigPhoto()
251
    {
252 5
        return $this->bigPhoto;
253
    }
254
255
    /**
256
     * Retrieve the outlet property
257
     *
258
     * @return Outlet|null
259
     */
260 3
    public function getOutlet()
261
    {
262 3
        return $this->outlet;
263
    }
264
265
    /**
266
     * Retrieve the outletCount property
267
     *
268
     * @return int|null
269
     */
270
    public function getOutletCount()
271
    {
272
        return $this->outletCount;
273
    }
274
275
    /**
276
     * Retrieve the warning property
277
     *
278
     * @return string|null
279
     */
280
    public function getWarning()
281
    {
282
        return $this->warning;
283
    }
284
285
    /**
286
     * Retrieve the age property
287
     *
288
     * @return string|null
289
     */
290
    public function getAge()
291
    {
292
        return $this->age;
293
    }
294
295
    /**
296
     * Retrieve the vendor property
297
     *
298
     * @return Vendor|null
299
     */
300 5
    public function getVendor()
301
    {
302 5
        return $this->vendor;
303
    }
304
305
    /**
306
     * Retrieve the filters property
307
     *
308
     * @note Property available during /model/{model_id} request.
309
     *
310
     * @return Filters|null
311
     */
312 1
    public function getFilters()
313
    {
314 1
        return $this->filters;
315
    }
316
}
317