-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathConstants.php
More file actions
101 lines (99 loc) · 3.01 KB
/
Constants.php
File metadata and controls
101 lines (99 loc) · 3.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<?php
/**
* Iban
*
* @author Jan Schaedlich <schaedlich.jan@gmail.com>
* @copyright 2013 Jan Schaedlich
* @link https://github.com/jschaedl/Iban
*
* MIT LICENSE
*/
namespace IBAN\Core;
class Constants
{
public static $letterMapping = array(
1 => 'A',
2 => 'B',
3 => 'C',
4 => 'D',
5 => 'E',
6 => 'F',
7 => 'G',
8 => 'H',
9 => 'I',
10 => 'J',
11 => 'K',
12 => 'L',
13 => 'M',
14 => 'N',
15 => 'O',
16 => 'P',
17 => 'Q',
18 => 'R',
19 => 'S',
20 => 'T',
21 => 'U',
22 => 'V',
23 => 'W',
24 => 'X',
25 => 'Y',
26 => 'Z'
);
public static $ibanFormatMap = array(
'AL' => '[0-9]{8}[0-9A-Z]{16}',
'AD' => '[0-9]{8}[0-9A-Z]{12}',
'AT' => '[0-9]{16}',
'BE' => '[0-9]{12}',
'BA' => '[0-9]{16}',
'BG' => '[A-Z]{4}[0-9]{6}[0-9A-Z]{8}',
'HR' => '[0-9]{17}',
'CY' => '[0-9]{8}[0-9A-Z]{16}',
'CZ' => '[0-9]{20}',
'DK' => '[0-9]{14}',
'EE' => '[0-9]{16}',
'FO' => '[0-9]{14}',
'FI' => '[0-9]{14}',
'FR' => '[0-9]{10}[0-9A-Z]{11}[0-9]{2}',
'GE' => '[0-9A-Z]{2}[0-9]{16}',
'DE' => '[0-9]{18}',
'GI' => '[A-Z]{4}[0-9A-Z]{15}',
'GR' => '[0-9]{7}[0-9A-Z]{16}',
'GL' => '[0-9]{14}',
'HU' => '[0-9]{24}',
'IS' => '[0-9]{22}',
'IE' => '[0-9A-Z]{4}[0-9]{14}',
'IL' => '[0-9]{19}',
'IT' => '[A-Z][0-9]{10}[0-9A-Z]{12}',
'KZ' => '[0-9]{3}[0-9A-Z]{13}',
'KW' => '[A-Z]{4}[0-9]{22}',
'LV' => '[A-Z]{4}[0-9A-Z]{13}',
'LB' => '[0-9]{4}[0-9A-Z]{20}',
'LI' => '[0-9]{5}[0-9A-Z]{12}',
'LT' => '[0-9]{16}',
'LU' => '[0-9]{3}[0-9A-Z]{13}',
'MK' => '[0-9]{3}[0-9A-Z]{10}[0-9]{2}',
'MT' => '[A-Z]{4}[0-9]{5}[0-9A-Z]{18}',
'MR' => '[0-9]{23}',
'MU' => '[A-Z]{4}[0-9]{19}[A-Z]{3}',
'MC' => '[0-9]{10}[0-9A-Z]{11}[0-9]{2}',
'ME' => '[0-9]{18}',
'NL' => '[A-Z]{4}[0-9]{10}',
'NO' => '[0-9]{11}',
'PL' => '[0-9]{24}',
'PT' => '[0-9]{21}',
'RO' => '[A-Z]{4}[0-9A-Z]{16}',
'SM' => '[A-Z][0-9]{10}[0-9A-Z]{12}',
'SA' => '[0-9]{2}[0-9A-Z]{18}',
'RS' => '[0-9]{18}',
'SK' => '[0-9]{20}',
'SI' => '[0-9]{15}',
'ES' => '[0-9]{20}',
'SE' => '[0-9]{20}',
'CH' => '[0-9]{5}[0-9A-Z]{12}',
'TN' => '[0-9]{20}',
'TR' => '[0-9]{5}[0-9A-Z]{17}',
'AE' => '[0-9]{19}',
'GB' => '[A-Z]{4}[0-9]{14}',
'XK' => '[0-9]{16}'
);
}