Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
100.00% |
4 / 4 |
|
100.00% |
4 / 4 |
CRAP | |
100.00% |
1 / 1 |
| Iban | |
100.00% |
4 / 4 |
|
100.00% |
4 / 4 |
4 | |
100.00% |
1 / 1 |
| getCountry | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| getChars | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| getBban | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| getFields | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| 1 | <?php |
| 2 | /** |
| 3 | * Jingga |
| 4 | * |
| 5 | * PHP Version 8.1 |
| 6 | * |
| 7 | * @package phpOMS\Localization\Defaults |
| 8 | * @copyright Dennis Eichhorn |
| 9 | * @license OMS License 2.0 |
| 10 | * @version 1.0.0 |
| 11 | * @link https://jingga.app |
| 12 | */ |
| 13 | declare(strict_types=1); |
| 14 | |
| 15 | namespace phpOMS\Localization\Defaults; |
| 16 | |
| 17 | /** |
| 18 | * iban class. |
| 19 | * |
| 20 | * @package phpOMS\Localization\Defaults |
| 21 | * @license OMS License 2.0 |
| 22 | * @link https://jingga.app |
| 23 | * @since 1.0.0 |
| 24 | */ |
| 25 | class Iban |
| 26 | { |
| 27 | /** |
| 28 | * Iban id. |
| 29 | * |
| 30 | * @var int |
| 31 | * @since 1.0.0 |
| 32 | */ |
| 33 | public int $id = 0; |
| 34 | |
| 35 | /** |
| 36 | * Iban country. |
| 37 | * |
| 38 | * @var string |
| 39 | * @since 1.0.0 |
| 40 | */ |
| 41 | protected string $country = ''; |
| 42 | |
| 43 | /** |
| 44 | * Iban chars. |
| 45 | * |
| 46 | * @var int |
| 47 | * @since 1.0.0 |
| 48 | */ |
| 49 | protected int $chars = 2; |
| 50 | |
| 51 | /** |
| 52 | * Iban bban. |
| 53 | * |
| 54 | * @var string |
| 55 | * @since 1.0.0 |
| 56 | */ |
| 57 | protected string $bban = ''; |
| 58 | |
| 59 | /** |
| 60 | * Iban fields. |
| 61 | * |
| 62 | * @var string |
| 63 | * @since 1.0.0 |
| 64 | */ |
| 65 | protected string $fields = ''; |
| 66 | |
| 67 | /** |
| 68 | * Get iban country |
| 69 | * |
| 70 | * @return string |
| 71 | * |
| 72 | * @since 1.0.0 |
| 73 | */ |
| 74 | public function getCountry() : string |
| 75 | { |
| 76 | return $this->country; |
| 77 | } |
| 78 | |
| 79 | /** |
| 80 | * Get iban chars |
| 81 | * |
| 82 | * @return int |
| 83 | * |
| 84 | * @since 1.0.0 |
| 85 | */ |
| 86 | public function getChars() : int |
| 87 | { |
| 88 | return $this->chars; |
| 89 | } |
| 90 | |
| 91 | /** |
| 92 | * Get iban bban |
| 93 | * |
| 94 | * @return string |
| 95 | * |
| 96 | * @since 1.0.0 |
| 97 | */ |
| 98 | public function getBban() : string |
| 99 | { |
| 100 | return $this->bban; |
| 101 | } |
| 102 | |
| 103 | /** |
| 104 | * Get iban fields |
| 105 | * |
| 106 | * @return string |
| 107 | * |
| 108 | * @since 1.0.0 |
| 109 | */ |
| 110 | public function getFields() : string |
| 111 | { |
| 112 | return $this->fields; |
| 113 | } |
| 114 | } |