Passed
Push — develop ( f8140e...dbb7b9 )
by Jens
10:17
created

MatchingPriceNotFoundError   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 1
eloc 10
dl 0
loc 15
c 0
b 0
f 0
ccs 0
cts 9
cp 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A fieldDefinitions() 0 11 1
1
<?php
2
/**
3
 */
4
5
namespace Commercetools\Core\Error;
6
7
use Commercetools\Core\Model\Channel\ChannelReference;
8
use Commercetools\Core\Model\CustomerGroup\CustomerGroupReference;
9
10
/**
11
 * @package Commercetools\Core\Error
12
 *
13
 * @method string getCode()
14
 * @method MatchingPriceNotFoundError setCode(string $code = null)
15
 * @method string getMessage()
16
 * @method MatchingPriceNotFoundError setMessage(string $message = null)
17
 * @method string getProductId()
18
 * @method MatchingPriceNotFoundError setProductId(string $productId = null)
19
 * @method string getVariantId()
20
 * @method MatchingPriceNotFoundError setVariantId(string $variantId = null)
21
 * @method string getCurrency()
22
 * @method MatchingPriceNotFoundError setCurrency(string $currency = null)
23
 * @method string getCountry()
24
 * @method MatchingPriceNotFoundError setCountry(string $country = null)
25
 * @method CustomerGroupReference getCustomerGroup()
26
 * @method MatchingPriceNotFoundError setCustomerGroup(CustomerGroupReference $customerGroup = null)
27
 * @method ChannelReference getChannel()
28
 * @method MatchingPriceNotFoundError setChannel(ChannelReference $channel = null)
29
 */
30
class MatchingPriceNotFoundError extends ApiError
31
{
32
    const CODE = 'MatchingPriceNotFound';
33
34
    public function fieldDefinitions()
35
    {
36
        $definitions = parent::fieldDefinitions();
37
        $definitions['productId'] = [static::TYPE => 'string'];
38
        $definitions['variantId'] = [static::TYPE => 'string'];
39
        $definitions['currency'] = [static::TYPE => 'string'];
40
        $definitions['country'] = [static::TYPE => 'string'];
41
        $definitions['customerGroup'] = [static::TYPE => CustomerGroupReference::class];
42
        $definitions['channel'] = [static::TYPE => ChannelReference::class];
43
44
        return $definitions;
45
    }
46
}
47