Completed
Push — master ( aa9657...bb9832 )
by Sebastian
05:21
created

Base   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 0
dl 0
loc 23
c 0
b 0
f 0
ccs 2
cts 2
cp 1
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getHint() 0 4 1
pass() 0 1 ?
1
<?php
2
/**
3
 * This file is part of CaptainHook.
4
 *
5
 * (c) Sebastian Feldmann <[email protected]>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
namespace SebastianFeldmann\CaptainHook\Hook\Message\Rule;
11
12
use SebastianFeldmann\Git\CommitMessage;
13
use SebastianFeldmann\CaptainHook\Hook\Message\Rule;
14
15
/**
16
 * Class Base
17
 *
18
 * @package CaptainHook
19
 * @author  Sebastian Feldmann <[email protected]>
20
 * @link    https://github.com/sebastianfeldmann/captainhook
21
 * @since   Class available since Release 0.9.0
22
 */
23
abstract class Base implements Rule
24
{
25
    /**
26
     * Rule hint.
27
     *
28
     * @var string
29
     */
30
    protected $hint;
31
32
    /**
33
     * @return string
34
     */
35 4
    public function getHint() : string
36
    {
37 4
        return $this->hint;
38
    }
39
40
    /**
41
     * @param  \SebastianFeldmann\Git\CommitMessage $msg
42
     * @return bool
43
     */
44
    abstract public function pass(CommitMessage $msg) : bool;
45
}
46