| Total Complexity | 5 |
| Total Lines | 51 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 8 | class Currencies extends AbstractDatabase |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * @return string |
||
| 12 | */ |
||
| 13 | public static function getISONumber() |
||
| 16 | } |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @param array $entry |
||
| 20 | * |
||
| 21 | * @return Currency |
||
| 22 | */ |
||
| 23 | protected function arrayToEntry(array $entry) |
||
| 24 | { |
||
| 25 | return new Currency( |
||
| 26 | $entry['name'], |
||
| 27 | $entry['alpha_3'], |
||
| 28 | (int)$entry['numeric'] |
||
| 29 | ); |
||
| 30 | } |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @return array |
||
| 34 | */ |
||
| 35 | protected function getIndexDefinition() |
||
| 40 | ]; |
||
| 41 | } |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @param string $code |
||
| 45 | * @return null|Currency |
||
| 46 | */ |
||
| 47 | public function getByLetterCode($code) |
||
| 50 | } |
||
| 51 | |||
| 52 | /** |
||
| 53 | * @param int $code |
||
| 54 | * @return null|Currency |
||
| 55 | */ |
||
| 56 | public function getByNumericCode($code) |
||
| 61 |