Bunq   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Importance

Changes 2
Bugs 0 Features 1
Metric Value
eloc 4
c 2
b 0
f 1
dl 0
loc 22
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A parseStatementBank() 0 3 1
A isApplicable() 0 5 1
1
<?php
2
3
namespace Kingsquare\Parser\Banking\Mt940\Engine;
4
5
use Kingsquare\Parser\Banking\Mt940\Engine;
6
7
class Bunq extends Engine
8
{
9
    /**
10
     *
11
     * {@inheritdoc}
12
     * @see \Kingsquare\Parser\Banking\Mt940\Engine::parseStatementBank()
13
     */
14
    protected function parseStatementBank()
15
    {
16
        return 'BUNQ';
17
    }
18
19
    /**
20
     *
21
     * {@inheritdoc}
22
     * @see \Kingsquare\Parser\Banking\Mt940\Engine::isApplicable()
23
     */
24
    public static function isApplicable($string)
25
    {
26
        $firstline = strtok($string, "\r\n\t");
27
28
        return strpos($firstline, 'BUNQ') !== false;
29
    }
30
}
31