V06   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Test Coverage

Coverage 83.33%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 9
dl 0
loc 25
ccs 10
cts 12
cp 0.8333
rs 10
c 1
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getXmlNs() 0 3 1
A getName() 0 3 1
A getDecoder() 0 8 1
A getMsgId() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Genkgo\Camt\Camt052\MessageFormat;
6
7
use Genkgo\Camt\Camt052;
8
use Genkgo\Camt\Decoder;
9
use Genkgo\Camt\DecoderInterface;
10
use Genkgo\Camt\MessageFormatInterface;
11
12
final class V06 implements MessageFormatInterface
13
{
14 2
    public function getXmlNs(): string
15
    {
16 2
        return 'urn:iso:std:iso:20022:tech:xsd:camt.052.001.06';
17
    }
18
19 1
    public function getMsgId(): string
20
    {
21 1
        return 'camt.052.001.06';
22
    }
23
24
    public function getName(): string
25
    {
26
        return 'BankToCustomerAccountReportV06';
27
    }
28
29 1
    public function getDecoder(): DecoderInterface
30
    {
31 1
        $entryTransactionDetailDecoder = new Camt052\Decoder\EntryTransactionDetail(new Decoder\Date());
32 1
        $entryDecoder = new Decoder\Entry($entryTransactionDetailDecoder);
33 1
        $recordDecoder = new Decoder\Record($entryDecoder, new Decoder\Date());
34 1
        $messageDecoder = new Camt052\Decoder\V06\Message($recordDecoder, new Decoder\Date());
35
36 1
        return new Decoder($messageDecoder, sprintf('/assets/%s.xsd', $this->getMsgId()));
37
    }
38
}
39