GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

AbstractPrefetchDriver   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 80%

Importance

Changes 0
Metric Value
wmc 2
c 0
b 0
f 0
lcom 0
cbo 1
dl 0
loc 14
ccs 4
cts 5
cp 0.8
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 2
1
<?php
2
3
namespace Bernard\Driver;
4
5
/**
6
 * For some drivers it gives a performance boost not to query the backend
7
 * all the time. This is mostly for SQS and IronMQ.
8
 */
9
abstract class AbstractPrefetchDriver implements \Bernard\Driver
10
{
11
    protected $prefetch;
12
    protected $cache;
13
14
    /**
15
     * @param int|null $prefetch
16
     */
17 23
    public function __construct($prefetch = null)
18
    {
19 23
        $this->prefetch = $prefetch ? (int) $prefetch : 2;
20 23
        $this->cache = new PrefetchMessageCache();
21 23
    }
22
}
23