AbstractAuthenticator   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A with() 0 5 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of Laravel GitLab.
7
 *
8
 * (c) Graham Campbell <[email protected]>
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace GrahamCampbell\GitLab\Authenticators;
15
16
use Gitlab\Client;
17
18
/**
19
 * This is the abstract authenticator class.
20
 *
21
 * @author Graham Campbell <[email protected]>
22
 */
23
abstract class AbstractAuthenticator implements AuthenticatorInterface
24
{
25
    /**
26
     * The client to perform the authentication on.
27
     *
28
     * @var \Gitlab\Client|null
29
     */
30
    protected $client;
31
32
    /**
33
     * Set the client to perform the authentication on.
34
     *
35
     * @param \Gitlab\Client $client
36
     *
37
     * @return \GrahamCampbell\GitLab\Authenticators\AuthenticatorInterface
38
     */
39 180
    public function with(Client $client)
40
    {
41 180
        $this->client = $client;
42
43 180
        return $this;
44
    }
45
}
46