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.
Completed
Push — master ( 490bf5...2ea53f )
by Cees-Jan
06:11
created

CreateStatusCommand   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 73
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 6
lcom 0
cbo 0
dl 0
loc 73
rs 10
c 0
b 0
f 0

6 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 1
A getCommit() 0 4 1
A getState() 0 4 1
A getTargetUrl() 0 4 1
A getDescription() 0 4 1
A getContext() 0 4 1
1
<?php declare(strict_types=1);
2
3
namespace ApiClients\Client\Github\CommandBus\Command\Repository\Commit;
4
5
use ApiClients\Client\Github\Resource\Repository\CommitInterface;
6
use WyriHaximus\Tactician\CommandHandler\Annotations\Handler;
7
8
/**
9
 * @Handler("ApiClients\Client\Github\CommandBus\Handler\Repository\Commit\CreateStatusHandler")
10
 */
11
final class CreateStatusCommand
12
{
13
    /** @var CommitInterface */
14
    private $commit;
15
16
    /** @var string */
17
    private $state;
18
19
    /** @var null|string */
20
    private $targetUrl;
21
22
    /** @var null|string */
23
    private $description;
24
25
    /** @var null|string */
26
    private $context;
27
28
    /**
29
     * @param CommitInterface $commit
30
     * @param string          $state
31
     * @param string|null     $targetUrl
32
     * @param string|null     $description
33
     * @param string|null     $context
34
     */
35
    public function __construct(CommitInterface $commit, string $state, ?string $targetUrl = null, ?string $description = null, ?string $context = null)
36
    {
37
        $this->commit = $commit;
38
        $this->state = $state;
39
        $this->targetUrl = $targetUrl;
40
        $this->description = $description;
41
        $this->context = $context;
42
    }
43
44
    /**
45
     * @return CommitInterface
46
     */
47
    public function getCommit(): CommitInterface
48
    {
49
        return $this->commit;
50
    }
51
52
    /**
53
     * @return string
54
     */
55
    public function getState(): string
56
    {
57
        return $this->state;
58
    }
59
60
    /**
61
     * @return string|null
62
     */
63
    public function getTargetUrl(): ?string
64
    {
65
        return $this->targetUrl;
66
    }
67
68
    /**
69
     * @return string|null
70
     */
71
    public function getDescription(): ?string
72
    {
73
        return $this->description;
74
    }
75
76
    /**
77
     * @return string|null
78
     */
79
    public function getContext(): ?string
80
    {
81
        return $this->context;
82
    }
83
}
84