Completed
Push — master ( d7cdbc...2653c8 )
by Robin
13s queued 12s
created

Bunq::parseStatementBank()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
cc 1
eloc 1
c 1
b 0
f 1
nc 1
nop 0
dl 0
loc 3
rs 10
1
<?php
2
namespace Kingsquare\Parser\Banking\Mt940\Engine;
3
4
use Kingsquare\Parser\Banking\Mt940\Engine;
5
6
class Bunq extends Engine
7
{
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