Passed
Push — develop ( 92e1e8...d25e3e )
by Jens
12:17
created

OrderEditReference   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
eloc 4
dl 0
loc 13
c 0
b 0
f 0
ccs 2
cts 2
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A ofId() 0 3 1
1
<?php
2
/**
3
 */
4
5
namespace Commercetools\Core\Model\OrderEdit;
6
7
use Commercetools\Core\Model\Common\Context;
8
use Commercetools\Core\Model\Common\Reference;
9
10
/**
11
 * @package Commercetools\Core\Model\OrderEdit
12
 *
13
 * @method string getTypeId()
14
 * @method OrderEditReference setTypeId(string $typeId = null)
15
 * @method string getId()
16
 * @method OrderEditReference setId(string $id = null)
17
 * @method string getKey()
18
 * @method OrderEditReference setKey(string $key = null)
19
 * @method OrderEdit getObj()
20
 * @method OrderEditReference setObj(OrderEdit $obj = null)
21
 */
22
class OrderEditReference extends Reference
23
{
24
    const TYPE_ORDER_EDIT = 'order-edit';
25
    const TYPE_CLASS = OrderEdit::class;
26
27
    /**
28
     * @param $id
29
     * @param Context|callable $context
30
     * @return OrderEditReference
31
     */
32 4
    public static function ofId($id, $context = null)
33
    {
34 4
        return static::ofTypeAndId(static::TYPE_ORDER_EDIT, $id, $context);
35
    }
36
}
37