Kti::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 7
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 8
ccs 7
cts 7
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 5
crap 1
1
<?php
2
3
namespace Fhp\DataTypes;
4
5
/**
6
 * Class Kti (Kontoverbindung International)
7
 *
8
 * @link http://www.hbci-zka.de/dokumente/spezifikation_deutsch/fintsv3/FinTS_3.0_Messages_Geschaeftsvorfaelle_2015-08-07_final_version.pdf
9
 * Section: B.3.2
10
 * @package Fhp\DataTypes
11
 */
12
class Kti
13
{
14
    /**
15
     * @var string
16
     */
17
    protected $iban;
18
19
    /**
20
     * @var string
21
     */
22
    protected $bic;
23
24
    /**
25
     * @var string
26
     */
27
    protected $accountNumber;
28
29
    /**
30
     * @var string
31
     */
32
    protected $subAccountFeature;
33
34
    /**
35
     * @var Kik
36
     */
37
    protected $kik;
38
39
    /**
40
     * Kti constructor.
41
     *
42
     * @param string $iban
43
     * @param string $bic
44
     * @param string $accountNumber
45
     * @param string $subAccountFeature
46
     * @param Kik $kik
47
     */
48 1
    public function __construct($iban, $bic, $accountNumber, $subAccountFeature, Kik $kik)
49
    {
50 1
        $this->iban = $iban;
51 1
        $this->bic = $bic;
52 1
        $this->accountNumber = $accountNumber;
53 1
        $this->subAccountFeature = $subAccountFeature;
54 1
        $this->kik = $kik;
55 1
    }
56
57
    /**
58
     * @return string
59
     */
60 1
    public function toString()
61
    {
62 1
        return $this->iban . ':'
63 1
            . $this->bic . ':'
64 1
            . $this->accountNumber . ':'
65 1
            . $this->subAccountFeature . ':'
66 1
            . (string) $this->kik;
67
    }
68
69
    /**
70
     * @return string
71
     */
72 1
    public function __toString()
73
    {
74 1
        return $this->toString();
75
    }
76
}
77