Completed
Push — master ( fa9a11...9c37c7 )
by Jens
13:15
created

FacetResultCollection   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 15
ccs 2
cts 2
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A getByName() 0 4 1
1
<?php
2
/**
3
 * @author @jayS-de <[email protected]>
4
 */
5
6
namespace Commercetools\Core\Model\Product;
7
8
use Commercetools\Core\Model\Common\Collection;
9
10
/**
11
 * @package Commercetools\Core\Model\Product
12
 * @method FacetResult current()
13
 * @method FacetResultCollection add(FacetResult $element)
14
 * @method FacetResult getAt($offset)
15
 */
16
class FacetResultCollection extends Collection
17
{
18
    const OFFSET = 'offset';
19
20
    protected $type = '\Commercetools\Core\Model\Product\FacetResult';
21
22
    /**
23
     * @param $name
24
     * @return FacetResult
25
     */
26 9
    public function getByName($name)
27
    {
28 9
        return $this->getAt($name);
29
    }
30
}
31