HNSHA::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 16

Duplication

Lines 16
Ratio 100 %

Code Coverage

Tests 10
CRAP Score 1

Importance

Changes 0
Metric Value
dl 16
loc 16
ccs 10
cts 10
cp 1
rs 9.7333
c 0
b 0
f 0
cc 1
nc 1
nop 3
crap 1
1
<?php
2
3
namespace Fhp\Segment;
4
5
use Fhp\DataTypes\Kik;
6
7
/**
8
 * Class HNSHA (Signaturabschluss)
9
 * Segment type: Administration
10
 *
11
 * @link: http://www.hbci-zka.de/dokumente/spezifikation_deutsch/fintsv3/FinTS_3.0_Security_Sicherheitsverfahren_HBCI_Rel_20130718_final_version.pdf
12
 * Section: B.5.2
13
 *
14
 * @package Fhp\Segment
15
 */
16 View Code Duplication
class HNSHA extends AbstractSegment
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
17
{
18
    const NAME = 'HNSHA';
19
    const VERSION = 2;
20
21
    /**
22
     * HNSHA constructor.
23
     * @param int $segmentNumber
24
     * @param string $securityControlReference
25
     * @param string $pin
26
     */
27 4
    public function __construct(
28
        $segmentNumber,
29
        $securityControlReference,
30
        $pin
31
    ) {
32 4
        parent::__construct(
33 4
            static::NAME,
34 4
            $segmentNumber,
35 4
            static::VERSION,
36
            array(
37 4
                $securityControlReference,
38 4
                '',
39
                $pin
40 4
            )
41 4
        );
42 4
    }
43
44
    /**
45
     * @return string
46
     */
47
    public function getName()
48
    {
49
        return static::NAME;
50
    }
51
}
52