Completed
Push — master ( 5da4b2...7163c3 )
by Miro
04:03 queued 01:19
created

GithubCommitSha::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
namespace DevBoardLib\GithubCore\Commit;
3
4
use DevBoardLib\GithubCore\Identifier;
5
6
/**
7
 * Class GithubCommitSha.
8
 */
9
class GithubCommitSha implements Identifier
10
{
11
    /** @var string */
12
    private $commitSha;
13
14
    /**
15
     * BranchId constructor.
16
     *
17
     * @param $commitSha
18
     */
19
    public function __construct($commitSha)
20
    {
21
        $this->commitSha = $commitSha;
22
    }
23
24
    /**
25
     * @return string
26
     */
27
    public function __toString()
28
    {
29
        return (string) $this->commitSha;
30
    }
31
}
32