UnreadCount   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
c 1
b 0
f 0
dl 0
loc 18
ccs 7
cts 7
cp 1
rs 10
wmc 3

2 Methods

Rating   Name   Duplication   Size   Complexity  
A max() 0 3 1
A unreadCounts() 0 7 2
1
<?php
2
3
declare(strict_types=1);
4
5
namespace ExileeD\Inoreader\Objects;
6
7
class UnreadCount extends AbstractObject implements ObjectInterface
8
{
9
10 3
    public function max(): int
11
    {
12 3
        return $this->data->max;
13
    }
14
15
    /**
16
     * @return SingleUnreadCount[]
17
     */
18 3
    public function unreadCounts(): array
19
    {
20 3
        $counts = [];
21 3
        foreach ($this->data->unreadcounts as $count) {
22 3
            $counts[] = new SingleUnreadCount($count);
23
        }
24 3
        return $counts;
25
    }
26
}
27