From 6578dab6246a965d27fb81d2afbdfa17a3ac087b Mon Sep 17 00:00:00 2001 From: Tom Kay Date: Thu, 5 Mar 2020 17:04:24 +0000 Subject: [PATCH] Trim format (#22) * test currency format + trim * add decimals * fix test for decimals --- src/Currency/AbstractCurrency.php | 26 +++++++++++++------------ src/Currency/Currencies/AEDCurrency.php | 5 +++++ src/Currency/Currencies/AFNCurrency.php | 5 +++++ src/Currency/Currencies/ALLCurrency.php | 5 +++++ src/Currency/Currencies/AMDCurrency.php | 5 +++++ src/Currency/Currencies/ANGCurrency.php | 5 +++++ src/Currency/Currencies/AOACurrency.php | 5 +++++ src/Currency/Currencies/ARSCurrency.php | 5 +++++ src/Currency/Currencies/ATSCurrency.php | 5 +++++ src/Currency/Currencies/AUDCurrency.php | 5 +++++ src/Currency/Currencies/AWGCurrency.php | 5 +++++ src/Currency/Currencies/AZNCurrency.php | 5 +++++ src/Currency/Currencies/BAMCurrency.php | 5 +++++ src/Currency/Currencies/BBDCurrency.php | 5 +++++ src/Currency/Currencies/BDTCurrency.php | 5 +++++ src/Currency/Currencies/BEFCurrency.php | 5 +++++ src/Currency/Currencies/BGNCurrency.php | 5 +++++ src/Currency/Currencies/BHDCurrency.php | 5 +++++ src/Currency/Currencies/BIFCurrency.php | 5 +++++ src/Currency/Currencies/BMDCurrency.php | 5 +++++ src/Currency/Currencies/BNDCurrency.php | 5 +++++ src/Currency/Currencies/BOBCurrency.php | 5 +++++ src/Currency/Currencies/BRLCurrency.php | 5 +++++ src/Currency/Currencies/BSDCurrency.php | 5 +++++ src/Currency/Currencies/BTNCurrency.php | 5 +++++ src/Currency/Currencies/BWPCurrency.php | 5 +++++ src/Currency/Currencies/BYRCurrency.php | 5 +++++ src/Currency/Currencies/BZDCurrency.php | 5 +++++ src/Currency/Currencies/CADCurrency.php | 5 +++++ src/Currency/Currencies/CDFCurrency.php | 5 +++++ src/Currency/Currencies/CHFCurrency.php | 5 +++++ src/Currency/Currencies/CLFCurrency.php | 5 +++++ src/Currency/Currencies/CLPCurrency.php | 5 +++++ src/Currency/Currencies/CNYCurrency.php | 5 +++++ src/Currency/Currencies/COPCurrency.php | 5 +++++ src/Currency/Currencies/CRCCurrency.php | 5 +++++ src/Currency/Currencies/CSDCurrency.php | 5 +++++ src/Currency/Currencies/CUPCurrency.php | 5 +++++ src/Currency/Currencies/CVECurrency.php | 5 +++++ src/Currency/Currencies/CYPCurrency.php | 5 +++++ src/Currency/Currencies/CZKCurrency.php | 5 +++++ src/Currency/Currencies/DEMCurrency.php | 5 +++++ src/Currency/Currencies/DJFCurrency.php | 5 +++++ src/Currency/Currencies/DKKCurrency.php | 5 +++++ src/Currency/Currencies/DOPCurrency.php | 5 +++++ src/Currency/Currencies/DZDCurrency.php | 5 +++++ src/Currency/Currencies/EEKCurrency.php | 5 +++++ src/Currency/Currencies/EGPCurrency.php | 5 +++++ src/Currency/Currencies/ERNCurrency.php | 5 +++++ src/Currency/Currencies/ESPCurrency.php | 5 +++++ src/Currency/Currencies/ETBCurrency.php | 5 +++++ src/Currency/Currencies/EURCurrency.php | 5 +++++ src/Currency/Currencies/FIMCurrency.php | 5 +++++ src/Currency/Currencies/FJDCurrency.php | 5 +++++ src/Currency/Currencies/FKPCurrency.php | 5 +++++ src/Currency/Currencies/FRFCurrency.php | 5 +++++ src/Currency/Currencies/GBPCurrency.php | 5 +++++ src/Currency/Currencies/GELCurrency.php | 5 +++++ src/Currency/Currencies/GHCCurrency.php | 5 +++++ src/Currency/Currencies/GHSCurrency.php | 5 +++++ src/Currency/Currencies/GIPCurrency.php | 5 +++++ src/Currency/Currencies/GMDCurrency.php | 5 +++++ src/Currency/Currencies/GRDCurrency.php | 5 +++++ src/Currency/Currencies/GTQCurrency.php | 5 +++++ src/Currency/Currencies/GYDCurrency.php | 5 +++++ src/Currency/Currencies/HKDCurrency.php | 5 +++++ src/Currency/Currencies/HNLCurrency.php | 5 +++++ src/Currency/Currencies/HRKCurrency.php | 5 +++++ src/Currency/Currencies/HTGCurrency.php | 5 +++++ src/Currency/Currencies/HUFCurrency.php | 5 +++++ src/Currency/Currencies/IDRCurrency.php | 5 +++++ src/Currency/Currencies/IEPCurrency.php | 5 +++++ src/Currency/Currencies/ILSCurrency.php | 5 +++++ src/Currency/Currencies/INRCurrency.php | 5 +++++ src/Currency/Currencies/IQDCurrency.php | 5 +++++ src/Currency/Currencies/IRRCurrency.php | 5 +++++ src/Currency/Currencies/ISKCurrency.php | 5 +++++ src/Currency/Currencies/ITLCurrency.php | 5 +++++ src/Currency/Currencies/JMDCurrency.php | 5 +++++ src/Currency/Currencies/JODCurrency.php | 5 +++++ src/Currency/Currencies/JPYCurrency.php | 5 +++++ src/Currency/Currencies/KESCurrency.php | 5 +++++ src/Currency/Currencies/KGSCurrency.php | 5 +++++ src/Currency/Currencies/KHRCurrency.php | 5 +++++ src/Currency/Currencies/KMFCurrency.php | 5 +++++ src/Currency/Currencies/KPWCurrency.php | 5 +++++ src/Currency/Currencies/KRWCurrency.php | 5 +++++ src/Currency/Currencies/KWDCurrency.php | 5 +++++ src/Currency/Currencies/KYDCurrency.php | 5 +++++ src/Currency/Currencies/KZTCurrency.php | 5 +++++ src/Currency/Currencies/LAKCurrency.php | 5 +++++ src/Currency/Currencies/LBPCurrency.php | 5 +++++ src/Currency/Currencies/LKRCurrency.php | 5 +++++ src/Currency/Currencies/LRDCurrency.php | 5 +++++ src/Currency/Currencies/LSLCurrency.php | 5 +++++ src/Currency/Currencies/LTLCurrency.php | 5 +++++ src/Currency/Currencies/LUFCurrency.php | 5 +++++ src/Currency/Currencies/LVLCurrency.php | 5 +++++ src/Currency/Currencies/LYDCurrency.php | 5 +++++ src/Currency/Currencies/MADCurrency.php | 5 +++++ src/Currency/Currencies/MDLCurrency.php | 5 +++++ src/Currency/Currencies/MGACurrency.php | 5 +++++ src/Currency/Currencies/MKDCurrency.php | 5 +++++ src/Currency/Currencies/MMKCurrency.php | 5 +++++ src/Currency/Currencies/MNTCurrency.php | 5 +++++ src/Currency/Currencies/MOPCurrency.php | 5 +++++ src/Currency/Currencies/MROCurrency.php | 5 +++++ src/Currency/Currencies/MTLCurrency.php | 5 +++++ src/Currency/Currencies/MURCurrency.php | 5 +++++ src/Currency/Currencies/MVRCurrency.php | 5 +++++ src/Currency/Currencies/MWKCurrency.php | 5 +++++ src/Currency/Currencies/MXNCurrency.php | 5 +++++ src/Currency/Currencies/MYRCurrency.php | 5 +++++ src/Currency/Currencies/MZMCurrency.php | 5 +++++ src/Currency/Currencies/MZNCurrency.php | 5 +++++ src/Currency/Currencies/NADCurrency.php | 5 +++++ src/Currency/Currencies/NGNCurrency.php | 5 +++++ src/Currency/Currencies/NIOCurrency.php | 5 +++++ src/Currency/Currencies/NLGCurrency.php | 5 +++++ src/Currency/Currencies/NOKCurrency.php | 5 +++++ src/Currency/Currencies/NPRCurrency.php | 5 +++++ src/Currency/Currencies/NZDCurrency.php | 5 +++++ src/Currency/Currencies/OMRCurrency.php | 5 +++++ src/Currency/Currencies/PABCurrency.php | 5 +++++ src/Currency/Currencies/PENCurrency.php | 5 +++++ src/Currency/Currencies/PGKCurrency.php | 5 +++++ src/Currency/Currencies/PHPCurrency.php | 5 +++++ src/Currency/Currencies/PKRCurrency.php | 5 +++++ src/Currency/Currencies/PLNCurrency.php | 5 +++++ src/Currency/Currencies/PTECurrency.php | 5 +++++ src/Currency/Currencies/PYGCurrency.php | 5 +++++ src/Currency/Currencies/QARCurrency.php | 5 +++++ src/Currency/Currencies/ROLCurrency.php | 5 +++++ src/Currency/Currencies/RONCurrency.php | 5 +++++ src/Currency/Currencies/RSDCurrency.php | 5 +++++ src/Currency/Currencies/RUBCurrency.php | 5 +++++ src/Currency/Currencies/RWFCurrency.php | 5 +++++ src/Currency/Currencies/SARCurrency.php | 5 +++++ src/Currency/Currencies/SBDCurrency.php | 5 +++++ src/Currency/Currencies/SCRCurrency.php | 5 +++++ src/Currency/Currencies/SDDCurrency.php | 5 +++++ src/Currency/Currencies/SEKCurrency.php | 5 +++++ src/Currency/Currencies/SGDCurrency.php | 5 +++++ src/Currency/Currencies/SHPCurrency.php | 5 +++++ src/Currency/Currencies/SITCurrency.php | 5 +++++ src/Currency/Currencies/SKKCurrency.php | 5 +++++ src/Currency/Currencies/SLLCurrency.php | 5 +++++ src/Currency/Currencies/SOSCurrency.php | 5 +++++ src/Currency/Currencies/SRDCurrency.php | 5 +++++ src/Currency/Currencies/STDCurrency.php | 5 +++++ src/Currency/Currencies/SVCCurrency.php | 5 +++++ src/Currency/Currencies/SYPCurrency.php | 5 +++++ src/Currency/Currencies/SZLCurrency.php | 5 +++++ src/Currency/Currencies/THBCurrency.php | 5 +++++ src/Currency/Currencies/TJSCurrency.php | 5 +++++ src/Currency/Currencies/TMMCurrency.php | 5 +++++ src/Currency/Currencies/TMTCurrency.php | 5 +++++ src/Currency/Currencies/TNDCurrency.php | 5 +++++ src/Currency/Currencies/TOPCurrency.php | 5 +++++ src/Currency/Currencies/TRYCurrency.php | 5 +++++ src/Currency/Currencies/TTDCurrency.php | 5 +++++ src/Currency/Currencies/TWDCurrency.php | 5 +++++ src/Currency/Currencies/TZSCurrency.php | 5 +++++ src/Currency/Currencies/UAHCurrency.php | 5 +++++ src/Currency/Currencies/UGXCurrency.php | 5 +++++ src/Currency/Currencies/USDCurrency.php | 5 +++++ src/Currency/Currencies/UYUCurrency.php | 5 +++++ src/Currency/Currencies/UZSCurrency.php | 5 +++++ src/Currency/Currencies/VEFCurrency.php | 5 +++++ src/Currency/Currencies/VNDCurrency.php | 5 +++++ src/Currency/Currencies/VUVCurrency.php | 5 +++++ src/Currency/Currencies/WSTCurrency.php | 5 +++++ src/Currency/Currencies/XCDCurrency.php | 5 +++++ src/Currency/Currencies/XPFCurrency.php | 5 +++++ src/Currency/Currencies/YERCurrency.php | 5 +++++ src/Currency/Currencies/ZARCurrency.php | 5 +++++ src/Currency/Currencies/ZMKCurrency.php | 5 +++++ src/Currency/Currencies/ZMWCurrency.php | 5 +++++ src/Currency/Currencies/ZWDCurrency.php | 5 +++++ src/Currency/Currencies/build/csv.php | 5 +++++ tests/Currency/CurrencyTest.php | 9 +++++++++ 181 files changed, 918 insertions(+), 12 deletions(-) diff --git a/src/Currency/AbstractCurrency.php b/src/Currency/AbstractCurrency.php index e39aa67..c248d52 100644 --- a/src/Currency/AbstractCurrency.php +++ b/src/Currency/AbstractCurrency.php @@ -33,18 +33,20 @@ public function getUSDAverageValue($value) public function format($amount, $showSymbol = true, $showCode = false) { - return str_replace( - [ - '{symbol}', - '{number}', - '{code}', - ], - [ - $showSymbol ? $this->getSymbol() : '', - $this->numberFormat($amount), - $showCode ? $this->getCode() : '', - ], - $this->_getRenderFormat($amount) + return trim( + str_replace( + [ + '{symbol}', + '{number}', + '{code}', + ], + [ + $showSymbol ? $this->getSymbol() : '', + $this->numberFormat($amount), + $showCode ? $this->getCode() : '', + ], + $this->_getRenderFormat($amount) + ) ); } diff --git a/src/Currency/Currencies/AEDCurrency.php b/src/Currency/Currencies/AEDCurrency.php index 47416dd..2ff7444 100644 --- a/src/Currency/Currencies/AEDCurrency.php +++ b/src/Currency/Currencies/AEDCurrency.php @@ -5,6 +5,11 @@ class AEDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'AED'; diff --git a/src/Currency/Currencies/AFNCurrency.php b/src/Currency/Currencies/AFNCurrency.php index fbaa529..e0bc8be 100644 --- a/src/Currency/Currencies/AFNCurrency.php +++ b/src/Currency/Currencies/AFNCurrency.php @@ -5,6 +5,11 @@ class AFNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '؋'; diff --git a/src/Currency/Currencies/ALLCurrency.php b/src/Currency/Currencies/ALLCurrency.php index b50bb61..4b8e790 100644 --- a/src/Currency/Currencies/ALLCurrency.php +++ b/src/Currency/Currencies/ALLCurrency.php @@ -5,6 +5,11 @@ class ALLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Lek'; diff --git a/src/Currency/Currencies/AMDCurrency.php b/src/Currency/Currencies/AMDCurrency.php index 829e83d..5e30b5c 100644 --- a/src/Currency/Currencies/AMDCurrency.php +++ b/src/Currency/Currencies/AMDCurrency.php @@ -5,6 +5,11 @@ class AMDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'AMD'; diff --git a/src/Currency/Currencies/ANGCurrency.php b/src/Currency/Currencies/ANGCurrency.php index f24f6fc..aa0b8cc 100644 --- a/src/Currency/Currencies/ANGCurrency.php +++ b/src/Currency/Currencies/ANGCurrency.php @@ -5,6 +5,11 @@ class ANGCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ƒ'; diff --git a/src/Currency/Currencies/AOACurrency.php b/src/Currency/Currencies/AOACurrency.php index efe53e6..15fa50a 100644 --- a/src/Currency/Currencies/AOACurrency.php +++ b/src/Currency/Currencies/AOACurrency.php @@ -5,6 +5,11 @@ class AOACurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'AOA'; diff --git a/src/Currency/Currencies/ARSCurrency.php b/src/Currency/Currencies/ARSCurrency.php index 6f640fd..93fb3d2 100644 --- a/src/Currency/Currencies/ARSCurrency.php +++ b/src/Currency/Currencies/ARSCurrency.php @@ -5,6 +5,11 @@ class ARSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/ATSCurrency.php b/src/Currency/Currencies/ATSCurrency.php index 4b8a8e7..c36401a 100644 --- a/src/Currency/Currencies/ATSCurrency.php +++ b/src/Currency/Currencies/ATSCurrency.php @@ -5,6 +5,11 @@ class ATSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ATS'; diff --git a/src/Currency/Currencies/AUDCurrency.php b/src/Currency/Currencies/AUDCurrency.php index 1fcf0bf..f984384 100644 --- a/src/Currency/Currencies/AUDCurrency.php +++ b/src/Currency/Currencies/AUDCurrency.php @@ -5,6 +5,11 @@ class AUDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/AWGCurrency.php b/src/Currency/Currencies/AWGCurrency.php index 19ba9dd..e08cfdd 100644 --- a/src/Currency/Currencies/AWGCurrency.php +++ b/src/Currency/Currencies/AWGCurrency.php @@ -5,6 +5,11 @@ class AWGCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ƒ'; diff --git a/src/Currency/Currencies/AZNCurrency.php b/src/Currency/Currencies/AZNCurrency.php index 99a855f..a49f31d 100644 --- a/src/Currency/Currencies/AZNCurrency.php +++ b/src/Currency/Currencies/AZNCurrency.php @@ -5,6 +5,11 @@ class AZNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ман'; diff --git a/src/Currency/Currencies/BAMCurrency.php b/src/Currency/Currencies/BAMCurrency.php index af43fde..2d4d349 100644 --- a/src/Currency/Currencies/BAMCurrency.php +++ b/src/Currency/Currencies/BAMCurrency.php @@ -5,6 +5,11 @@ class BAMCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'KM'; diff --git a/src/Currency/Currencies/BBDCurrency.php b/src/Currency/Currencies/BBDCurrency.php index 5d042c3..ac89fd8 100644 --- a/src/Currency/Currencies/BBDCurrency.php +++ b/src/Currency/Currencies/BBDCurrency.php @@ -5,6 +5,11 @@ class BBDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/BDTCurrency.php b/src/Currency/Currencies/BDTCurrency.php index 6d7d748..dc36204 100644 --- a/src/Currency/Currencies/BDTCurrency.php +++ b/src/Currency/Currencies/BDTCurrency.php @@ -5,6 +5,11 @@ class BDTCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'BDT'; diff --git a/src/Currency/Currencies/BEFCurrency.php b/src/Currency/Currencies/BEFCurrency.php index 56d18ca..fbcd197 100644 --- a/src/Currency/Currencies/BEFCurrency.php +++ b/src/Currency/Currencies/BEFCurrency.php @@ -5,6 +5,11 @@ class BEFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'BEF'; diff --git a/src/Currency/Currencies/BGNCurrency.php b/src/Currency/Currencies/BGNCurrency.php index 1ad9401..bf53d57 100644 --- a/src/Currency/Currencies/BGNCurrency.php +++ b/src/Currency/Currencies/BGNCurrency.php @@ -5,6 +5,11 @@ class BGNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'лв'; diff --git a/src/Currency/Currencies/BHDCurrency.php b/src/Currency/Currencies/BHDCurrency.php index ef3f68c..34af93a 100644 --- a/src/Currency/Currencies/BHDCurrency.php +++ b/src/Currency/Currencies/BHDCurrency.php @@ -5,6 +5,11 @@ class BHDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return 'BHD'; diff --git a/src/Currency/Currencies/BIFCurrency.php b/src/Currency/Currencies/BIFCurrency.php index 217bb61..0cf4596 100644 --- a/src/Currency/Currencies/BIFCurrency.php +++ b/src/Currency/Currencies/BIFCurrency.php @@ -5,6 +5,11 @@ class BIFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'BIF'; diff --git a/src/Currency/Currencies/BMDCurrency.php b/src/Currency/Currencies/BMDCurrency.php index 76142e8..04dc276 100644 --- a/src/Currency/Currencies/BMDCurrency.php +++ b/src/Currency/Currencies/BMDCurrency.php @@ -5,6 +5,11 @@ class BMDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/BNDCurrency.php b/src/Currency/Currencies/BNDCurrency.php index 4955733..c39373a 100644 --- a/src/Currency/Currencies/BNDCurrency.php +++ b/src/Currency/Currencies/BNDCurrency.php @@ -5,6 +5,11 @@ class BNDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/BOBCurrency.php b/src/Currency/Currencies/BOBCurrency.php index e8d53ce..ee3247b 100644 --- a/src/Currency/Currencies/BOBCurrency.php +++ b/src/Currency/Currencies/BOBCurrency.php @@ -5,6 +5,11 @@ class BOBCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$b'; diff --git a/src/Currency/Currencies/BRLCurrency.php b/src/Currency/Currencies/BRLCurrency.php index 3aac686..fb6b6e7 100644 --- a/src/Currency/Currencies/BRLCurrency.php +++ b/src/Currency/Currencies/BRLCurrency.php @@ -5,6 +5,11 @@ class BRLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'R$'; diff --git a/src/Currency/Currencies/BSDCurrency.php b/src/Currency/Currencies/BSDCurrency.php index 8f29998..1feec89 100644 --- a/src/Currency/Currencies/BSDCurrency.php +++ b/src/Currency/Currencies/BSDCurrency.php @@ -5,6 +5,11 @@ class BSDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/BTNCurrency.php b/src/Currency/Currencies/BTNCurrency.php index 825986c..516fccc 100644 --- a/src/Currency/Currencies/BTNCurrency.php +++ b/src/Currency/Currencies/BTNCurrency.php @@ -5,6 +5,11 @@ class BTNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'BTN'; diff --git a/src/Currency/Currencies/BWPCurrency.php b/src/Currency/Currencies/BWPCurrency.php index b6efc6e..760c8b5 100644 --- a/src/Currency/Currencies/BWPCurrency.php +++ b/src/Currency/Currencies/BWPCurrency.php @@ -5,6 +5,11 @@ class BWPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'P'; diff --git a/src/Currency/Currencies/BYRCurrency.php b/src/Currency/Currencies/BYRCurrency.php index 7796682..5a7152a 100644 --- a/src/Currency/Currencies/BYRCurrency.php +++ b/src/Currency/Currencies/BYRCurrency.php @@ -5,6 +5,11 @@ class BYRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'p.'; diff --git a/src/Currency/Currencies/BZDCurrency.php b/src/Currency/Currencies/BZDCurrency.php index 8ea5b73..35af828 100644 --- a/src/Currency/Currencies/BZDCurrency.php +++ b/src/Currency/Currencies/BZDCurrency.php @@ -5,6 +5,11 @@ class BZDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'BZ$'; diff --git a/src/Currency/Currencies/CADCurrency.php b/src/Currency/Currencies/CADCurrency.php index 1fd34fd..191b596 100644 --- a/src/Currency/Currencies/CADCurrency.php +++ b/src/Currency/Currencies/CADCurrency.php @@ -5,6 +5,11 @@ class CADCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/CDFCurrency.php b/src/Currency/Currencies/CDFCurrency.php index 6d1f46d..260a34f 100644 --- a/src/Currency/Currencies/CDFCurrency.php +++ b/src/Currency/Currencies/CDFCurrency.php @@ -5,6 +5,11 @@ class CDFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'CDF'; diff --git a/src/Currency/Currencies/CHFCurrency.php b/src/Currency/Currencies/CHFCurrency.php index c60b904..ff77a4f 100644 --- a/src/Currency/Currencies/CHFCurrency.php +++ b/src/Currency/Currencies/CHFCurrency.php @@ -5,6 +5,11 @@ class CHFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'CHF'; diff --git a/src/Currency/Currencies/CLFCurrency.php b/src/Currency/Currencies/CLFCurrency.php index bd1c1bc..67b9608 100644 --- a/src/Currency/Currencies/CLFCurrency.php +++ b/src/Currency/Currencies/CLFCurrency.php @@ -5,6 +5,11 @@ class CLFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'CLF'; diff --git a/src/Currency/Currencies/CLPCurrency.php b/src/Currency/Currencies/CLPCurrency.php index f9a8c0d..f19e1c4 100644 --- a/src/Currency/Currencies/CLPCurrency.php +++ b/src/Currency/Currencies/CLPCurrency.php @@ -5,6 +5,11 @@ class CLPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/CNYCurrency.php b/src/Currency/Currencies/CNYCurrency.php index b46601d..01fa9e8 100644 --- a/src/Currency/Currencies/CNYCurrency.php +++ b/src/Currency/Currencies/CNYCurrency.php @@ -5,6 +5,11 @@ class CNYCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '¥'; diff --git a/src/Currency/Currencies/COPCurrency.php b/src/Currency/Currencies/COPCurrency.php index d371e49..bef333d 100644 --- a/src/Currency/Currencies/COPCurrency.php +++ b/src/Currency/Currencies/COPCurrency.php @@ -5,6 +5,11 @@ class COPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/CRCCurrency.php b/src/Currency/Currencies/CRCCurrency.php index f08fa50..0016716 100644 --- a/src/Currency/Currencies/CRCCurrency.php +++ b/src/Currency/Currencies/CRCCurrency.php @@ -5,6 +5,11 @@ class CRCCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₡'; diff --git a/src/Currency/Currencies/CSDCurrency.php b/src/Currency/Currencies/CSDCurrency.php index 496d2c0..09f1627 100644 --- a/src/Currency/Currencies/CSDCurrency.php +++ b/src/Currency/Currencies/CSDCurrency.php @@ -5,6 +5,11 @@ class CSDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'CSD'; diff --git a/src/Currency/Currencies/CUPCurrency.php b/src/Currency/Currencies/CUPCurrency.php index 9ab1f74..43d6809 100644 --- a/src/Currency/Currencies/CUPCurrency.php +++ b/src/Currency/Currencies/CUPCurrency.php @@ -5,6 +5,11 @@ class CUPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₱'; diff --git a/src/Currency/Currencies/CVECurrency.php b/src/Currency/Currencies/CVECurrency.php index 0ef11f4..d5f08e0 100644 --- a/src/Currency/Currencies/CVECurrency.php +++ b/src/Currency/Currencies/CVECurrency.php @@ -5,6 +5,11 @@ class CVECurrency extends AbstractCurrency { + public function getDecimalCount() + { + return  ; + } + public function getSymbol() { return 'CVE'; diff --git a/src/Currency/Currencies/CYPCurrency.php b/src/Currency/Currencies/CYPCurrency.php index ab6be66..b359590 100644 --- a/src/Currency/Currencies/CYPCurrency.php +++ b/src/Currency/Currencies/CYPCurrency.php @@ -5,6 +5,11 @@ class CYPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'CYP'; diff --git a/src/Currency/Currencies/CZKCurrency.php b/src/Currency/Currencies/CZKCurrency.php index 2148fcc..8b23920 100644 --- a/src/Currency/Currencies/CZKCurrency.php +++ b/src/Currency/Currencies/CZKCurrency.php @@ -5,6 +5,11 @@ class CZKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Kč'; diff --git a/src/Currency/Currencies/DEMCurrency.php b/src/Currency/Currencies/DEMCurrency.php index 220eb36..9de7c70 100644 --- a/src/Currency/Currencies/DEMCurrency.php +++ b/src/Currency/Currencies/DEMCurrency.php @@ -5,6 +5,11 @@ class DEMCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'DEM'; diff --git a/src/Currency/Currencies/DJFCurrency.php b/src/Currency/Currencies/DJFCurrency.php index 303fb70..d650a95 100644 --- a/src/Currency/Currencies/DJFCurrency.php +++ b/src/Currency/Currencies/DJFCurrency.php @@ -5,6 +5,11 @@ class DJFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'DJF'; diff --git a/src/Currency/Currencies/DKKCurrency.php b/src/Currency/Currencies/DKKCurrency.php index 46f24a8..5986d48 100644 --- a/src/Currency/Currencies/DKKCurrency.php +++ b/src/Currency/Currencies/DKKCurrency.php @@ -5,6 +5,11 @@ class DKKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'kr'; diff --git a/src/Currency/Currencies/DOPCurrency.php b/src/Currency/Currencies/DOPCurrency.php index ea49255..82f9a9a 100644 --- a/src/Currency/Currencies/DOPCurrency.php +++ b/src/Currency/Currencies/DOPCurrency.php @@ -5,6 +5,11 @@ class DOPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'RD$'; diff --git a/src/Currency/Currencies/DZDCurrency.php b/src/Currency/Currencies/DZDCurrency.php index 9e03076..c8c0524 100644 --- a/src/Currency/Currencies/DZDCurrency.php +++ b/src/Currency/Currencies/DZDCurrency.php @@ -5,6 +5,11 @@ class DZDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'DZD'; diff --git a/src/Currency/Currencies/EEKCurrency.php b/src/Currency/Currencies/EEKCurrency.php index 063871e..b6a803a 100644 --- a/src/Currency/Currencies/EEKCurrency.php +++ b/src/Currency/Currencies/EEKCurrency.php @@ -5,6 +5,11 @@ class EEKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'kr'; diff --git a/src/Currency/Currencies/EGPCurrency.php b/src/Currency/Currencies/EGPCurrency.php index d1c06a0..f8eac46 100644 --- a/src/Currency/Currencies/EGPCurrency.php +++ b/src/Currency/Currencies/EGPCurrency.php @@ -5,6 +5,11 @@ class EGPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/ERNCurrency.php b/src/Currency/Currencies/ERNCurrency.php index 176e2d7..621236a 100644 --- a/src/Currency/Currencies/ERNCurrency.php +++ b/src/Currency/Currencies/ERNCurrency.php @@ -5,6 +5,11 @@ class ERNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ERN'; diff --git a/src/Currency/Currencies/ESPCurrency.php b/src/Currency/Currencies/ESPCurrency.php index 3ea1c39..1924e71 100644 --- a/src/Currency/Currencies/ESPCurrency.php +++ b/src/Currency/Currencies/ESPCurrency.php @@ -5,6 +5,11 @@ class ESPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ESP'; diff --git a/src/Currency/Currencies/ETBCurrency.php b/src/Currency/Currencies/ETBCurrency.php index 03a5acd..89b7bd4 100644 --- a/src/Currency/Currencies/ETBCurrency.php +++ b/src/Currency/Currencies/ETBCurrency.php @@ -5,6 +5,11 @@ class ETBCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ETB'; diff --git a/src/Currency/Currencies/EURCurrency.php b/src/Currency/Currencies/EURCurrency.php index 67e921f..bec1047 100644 --- a/src/Currency/Currencies/EURCurrency.php +++ b/src/Currency/Currencies/EURCurrency.php @@ -6,6 +6,11 @@ class EURCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '€'; diff --git a/src/Currency/Currencies/FIMCurrency.php b/src/Currency/Currencies/FIMCurrency.php index 7277ed3..4df7c34 100644 --- a/src/Currency/Currencies/FIMCurrency.php +++ b/src/Currency/Currencies/FIMCurrency.php @@ -5,6 +5,11 @@ class FIMCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'FIM'; diff --git a/src/Currency/Currencies/FJDCurrency.php b/src/Currency/Currencies/FJDCurrency.php index e3c66f2..280972e 100644 --- a/src/Currency/Currencies/FJDCurrency.php +++ b/src/Currency/Currencies/FJDCurrency.php @@ -5,6 +5,11 @@ class FJDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/FKPCurrency.php b/src/Currency/Currencies/FKPCurrency.php index 34fa477..bb90ea4 100644 --- a/src/Currency/Currencies/FKPCurrency.php +++ b/src/Currency/Currencies/FKPCurrency.php @@ -5,6 +5,11 @@ class FKPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/FRFCurrency.php b/src/Currency/Currencies/FRFCurrency.php index f69a84a..db8dd03 100644 --- a/src/Currency/Currencies/FRFCurrency.php +++ b/src/Currency/Currencies/FRFCurrency.php @@ -5,6 +5,11 @@ class FRFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'FRF'; diff --git a/src/Currency/Currencies/GBPCurrency.php b/src/Currency/Currencies/GBPCurrency.php index 53f4a73..3d3da7d 100644 --- a/src/Currency/Currencies/GBPCurrency.php +++ b/src/Currency/Currencies/GBPCurrency.php @@ -5,6 +5,11 @@ class GBPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/GELCurrency.php b/src/Currency/Currencies/GELCurrency.php index bee5592..50c5d29 100644 --- a/src/Currency/Currencies/GELCurrency.php +++ b/src/Currency/Currencies/GELCurrency.php @@ -5,6 +5,11 @@ class GELCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'GEL'; diff --git a/src/Currency/Currencies/GHCCurrency.php b/src/Currency/Currencies/GHCCurrency.php index c650230..efaa944 100644 --- a/src/Currency/Currencies/GHCCurrency.php +++ b/src/Currency/Currencies/GHCCurrency.php @@ -5,6 +5,11 @@ class GHCCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '¢'; diff --git a/src/Currency/Currencies/GHSCurrency.php b/src/Currency/Currencies/GHSCurrency.php index 035c6dd..798edd4 100644 --- a/src/Currency/Currencies/GHSCurrency.php +++ b/src/Currency/Currencies/GHSCurrency.php @@ -5,6 +5,11 @@ class GHSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'GHS'; diff --git a/src/Currency/Currencies/GIPCurrency.php b/src/Currency/Currencies/GIPCurrency.php index c8d6931..b408741 100644 --- a/src/Currency/Currencies/GIPCurrency.php +++ b/src/Currency/Currencies/GIPCurrency.php @@ -5,6 +5,11 @@ class GIPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/GMDCurrency.php b/src/Currency/Currencies/GMDCurrency.php index 7735610..b54d2aa 100644 --- a/src/Currency/Currencies/GMDCurrency.php +++ b/src/Currency/Currencies/GMDCurrency.php @@ -5,6 +5,11 @@ class GMDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'GMD'; diff --git a/src/Currency/Currencies/GRDCurrency.php b/src/Currency/Currencies/GRDCurrency.php index 29c2e99..3a4be4a 100644 --- a/src/Currency/Currencies/GRDCurrency.php +++ b/src/Currency/Currencies/GRDCurrency.php @@ -5,6 +5,11 @@ class GRDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'GRD'; diff --git a/src/Currency/Currencies/GTQCurrency.php b/src/Currency/Currencies/GTQCurrency.php index 7a10182..0d92a9f 100644 --- a/src/Currency/Currencies/GTQCurrency.php +++ b/src/Currency/Currencies/GTQCurrency.php @@ -5,6 +5,11 @@ class GTQCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Q'; diff --git a/src/Currency/Currencies/GYDCurrency.php b/src/Currency/Currencies/GYDCurrency.php index caf9ab9..8dfe6f4 100644 --- a/src/Currency/Currencies/GYDCurrency.php +++ b/src/Currency/Currencies/GYDCurrency.php @@ -5,6 +5,11 @@ class GYDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/HKDCurrency.php b/src/Currency/Currencies/HKDCurrency.php index ac30916..85f5f14 100644 --- a/src/Currency/Currencies/HKDCurrency.php +++ b/src/Currency/Currencies/HKDCurrency.php @@ -5,6 +5,11 @@ class HKDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/HNLCurrency.php b/src/Currency/Currencies/HNLCurrency.php index bbead8b..7877349 100644 --- a/src/Currency/Currencies/HNLCurrency.php +++ b/src/Currency/Currencies/HNLCurrency.php @@ -5,6 +5,11 @@ class HNLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'L'; diff --git a/src/Currency/Currencies/HRKCurrency.php b/src/Currency/Currencies/HRKCurrency.php index ea4fc14..3c68a37 100644 --- a/src/Currency/Currencies/HRKCurrency.php +++ b/src/Currency/Currencies/HRKCurrency.php @@ -5,6 +5,11 @@ class HRKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'kn'; diff --git a/src/Currency/Currencies/HTGCurrency.php b/src/Currency/Currencies/HTGCurrency.php index b1e5cf5..6bd5600 100644 --- a/src/Currency/Currencies/HTGCurrency.php +++ b/src/Currency/Currencies/HTGCurrency.php @@ -5,6 +5,11 @@ class HTGCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'HTG'; diff --git a/src/Currency/Currencies/HUFCurrency.php b/src/Currency/Currencies/HUFCurrency.php index 2187802..0071044 100644 --- a/src/Currency/Currencies/HUFCurrency.php +++ b/src/Currency/Currencies/HUFCurrency.php @@ -5,6 +5,11 @@ class HUFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'Ft'; diff --git a/src/Currency/Currencies/IDRCurrency.php b/src/Currency/Currencies/IDRCurrency.php index 1678a13..884df64 100644 --- a/src/Currency/Currencies/IDRCurrency.php +++ b/src/Currency/Currencies/IDRCurrency.php @@ -5,6 +5,11 @@ class IDRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Rp'; diff --git a/src/Currency/Currencies/IEPCurrency.php b/src/Currency/Currencies/IEPCurrency.php index ccddbce..3ca8a60 100644 --- a/src/Currency/Currencies/IEPCurrency.php +++ b/src/Currency/Currencies/IEPCurrency.php @@ -5,6 +5,11 @@ class IEPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'IEP'; diff --git a/src/Currency/Currencies/ILSCurrency.php b/src/Currency/Currencies/ILSCurrency.php index c699299..5d891fa 100644 --- a/src/Currency/Currencies/ILSCurrency.php +++ b/src/Currency/Currencies/ILSCurrency.php @@ -5,6 +5,11 @@ class ILSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₪'; diff --git a/src/Currency/Currencies/INRCurrency.php b/src/Currency/Currencies/INRCurrency.php index f646c28..ee50109 100644 --- a/src/Currency/Currencies/INRCurrency.php +++ b/src/Currency/Currencies/INRCurrency.php @@ -5,6 +5,11 @@ class INRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return ''; diff --git a/src/Currency/Currencies/IQDCurrency.php b/src/Currency/Currencies/IQDCurrency.php index 1204019..3ed4809 100644 --- a/src/Currency/Currencies/IQDCurrency.php +++ b/src/Currency/Currencies/IQDCurrency.php @@ -5,6 +5,11 @@ class IQDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return 'IQD'; diff --git a/src/Currency/Currencies/IRRCurrency.php b/src/Currency/Currencies/IRRCurrency.php index b715cf4..4195a12 100644 --- a/src/Currency/Currencies/IRRCurrency.php +++ b/src/Currency/Currencies/IRRCurrency.php @@ -5,6 +5,11 @@ class IRRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '﷼'; diff --git a/src/Currency/Currencies/ISKCurrency.php b/src/Currency/Currencies/ISKCurrency.php index ad44a67..68d7822 100644 --- a/src/Currency/Currencies/ISKCurrency.php +++ b/src/Currency/Currencies/ISKCurrency.php @@ -5,6 +5,11 @@ class ISKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'kr'; diff --git a/src/Currency/Currencies/ITLCurrency.php b/src/Currency/Currencies/ITLCurrency.php index 3585ef4..02f33f6 100644 --- a/src/Currency/Currencies/ITLCurrency.php +++ b/src/Currency/Currencies/ITLCurrency.php @@ -5,6 +5,11 @@ class ITLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ITL'; diff --git a/src/Currency/Currencies/JMDCurrency.php b/src/Currency/Currencies/JMDCurrency.php index 82ba495..de914a1 100644 --- a/src/Currency/Currencies/JMDCurrency.php +++ b/src/Currency/Currencies/JMDCurrency.php @@ -5,6 +5,11 @@ class JMDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'J$'; diff --git a/src/Currency/Currencies/JODCurrency.php b/src/Currency/Currencies/JODCurrency.php index 83613a4..b7e83d0 100644 --- a/src/Currency/Currencies/JODCurrency.php +++ b/src/Currency/Currencies/JODCurrency.php @@ -5,6 +5,11 @@ class JODCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return 'JOD'; diff --git a/src/Currency/Currencies/JPYCurrency.php b/src/Currency/Currencies/JPYCurrency.php index 3676af3..38c5065 100644 --- a/src/Currency/Currencies/JPYCurrency.php +++ b/src/Currency/Currencies/JPYCurrency.php @@ -5,6 +5,11 @@ class JPYCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return '¥'; diff --git a/src/Currency/Currencies/KESCurrency.php b/src/Currency/Currencies/KESCurrency.php index c3fe095..0e32794 100644 --- a/src/Currency/Currencies/KESCurrency.php +++ b/src/Currency/Currencies/KESCurrency.php @@ -5,6 +5,11 @@ class KESCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'KES'; diff --git a/src/Currency/Currencies/KGSCurrency.php b/src/Currency/Currencies/KGSCurrency.php index c8e635e..2674a39 100644 --- a/src/Currency/Currencies/KGSCurrency.php +++ b/src/Currency/Currencies/KGSCurrency.php @@ -5,6 +5,11 @@ class KGSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'лв'; diff --git a/src/Currency/Currencies/KHRCurrency.php b/src/Currency/Currencies/KHRCurrency.php index 67ccb7b..46dd890 100644 --- a/src/Currency/Currencies/KHRCurrency.php +++ b/src/Currency/Currencies/KHRCurrency.php @@ -5,6 +5,11 @@ class KHRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '៛'; diff --git a/src/Currency/Currencies/KMFCurrency.php b/src/Currency/Currencies/KMFCurrency.php index 12561db..b2eddce 100644 --- a/src/Currency/Currencies/KMFCurrency.php +++ b/src/Currency/Currencies/KMFCurrency.php @@ -5,6 +5,11 @@ class KMFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'KMF'; diff --git a/src/Currency/Currencies/KPWCurrency.php b/src/Currency/Currencies/KPWCurrency.php index a491620..dc61803 100644 --- a/src/Currency/Currencies/KPWCurrency.php +++ b/src/Currency/Currencies/KPWCurrency.php @@ -5,6 +5,11 @@ class KPWCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₩'; diff --git a/src/Currency/Currencies/KRWCurrency.php b/src/Currency/Currencies/KRWCurrency.php index 8b5d64d..0ac683a 100644 --- a/src/Currency/Currencies/KRWCurrency.php +++ b/src/Currency/Currencies/KRWCurrency.php @@ -5,6 +5,11 @@ class KRWCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return '₩'; diff --git a/src/Currency/Currencies/KWDCurrency.php b/src/Currency/Currencies/KWDCurrency.php index 0d58268..b97a569 100644 --- a/src/Currency/Currencies/KWDCurrency.php +++ b/src/Currency/Currencies/KWDCurrency.php @@ -5,6 +5,11 @@ class KWDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return 'KWD'; diff --git a/src/Currency/Currencies/KYDCurrency.php b/src/Currency/Currencies/KYDCurrency.php index cfecdb6..9851fd6 100644 --- a/src/Currency/Currencies/KYDCurrency.php +++ b/src/Currency/Currencies/KYDCurrency.php @@ -5,6 +5,11 @@ class KYDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/KZTCurrency.php b/src/Currency/Currencies/KZTCurrency.php index 564393d..b28c632 100644 --- a/src/Currency/Currencies/KZTCurrency.php +++ b/src/Currency/Currencies/KZTCurrency.php @@ -5,6 +5,11 @@ class KZTCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'лв'; diff --git a/src/Currency/Currencies/LAKCurrency.php b/src/Currency/Currencies/LAKCurrency.php index 0502db9..254fed9 100644 --- a/src/Currency/Currencies/LAKCurrency.php +++ b/src/Currency/Currencies/LAKCurrency.php @@ -5,6 +5,11 @@ class LAKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₭'; diff --git a/src/Currency/Currencies/LBPCurrency.php b/src/Currency/Currencies/LBPCurrency.php index 34745cc..fc5088c 100644 --- a/src/Currency/Currencies/LBPCurrency.php +++ b/src/Currency/Currencies/LBPCurrency.php @@ -5,6 +5,11 @@ class LBPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/LKRCurrency.php b/src/Currency/Currencies/LKRCurrency.php index f1fc7f4..70f89e2 100644 --- a/src/Currency/Currencies/LKRCurrency.php +++ b/src/Currency/Currencies/LKRCurrency.php @@ -5,6 +5,11 @@ class LKRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₨'; diff --git a/src/Currency/Currencies/LRDCurrency.php b/src/Currency/Currencies/LRDCurrency.php index 1377be2..ff2c700 100644 --- a/src/Currency/Currencies/LRDCurrency.php +++ b/src/Currency/Currencies/LRDCurrency.php @@ -5,6 +5,11 @@ class LRDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/LSLCurrency.php b/src/Currency/Currencies/LSLCurrency.php index eeb055a..ef9494f 100644 --- a/src/Currency/Currencies/LSLCurrency.php +++ b/src/Currency/Currencies/LSLCurrency.php @@ -5,6 +5,11 @@ class LSLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'LSL'; diff --git a/src/Currency/Currencies/LTLCurrency.php b/src/Currency/Currencies/LTLCurrency.php index 4686a48..20ea200 100644 --- a/src/Currency/Currencies/LTLCurrency.php +++ b/src/Currency/Currencies/LTLCurrency.php @@ -5,6 +5,11 @@ class LTLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Lt'; diff --git a/src/Currency/Currencies/LUFCurrency.php b/src/Currency/Currencies/LUFCurrency.php index 05970aa..d19dc7f 100644 --- a/src/Currency/Currencies/LUFCurrency.php +++ b/src/Currency/Currencies/LUFCurrency.php @@ -5,6 +5,11 @@ class LUFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'LUF'; diff --git a/src/Currency/Currencies/LVLCurrency.php b/src/Currency/Currencies/LVLCurrency.php index 49f4d79..625129a 100644 --- a/src/Currency/Currencies/LVLCurrency.php +++ b/src/Currency/Currencies/LVLCurrency.php @@ -5,6 +5,11 @@ class LVLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Ls'; diff --git a/src/Currency/Currencies/LYDCurrency.php b/src/Currency/Currencies/LYDCurrency.php index fe1a2d4..8e6845c 100644 --- a/src/Currency/Currencies/LYDCurrency.php +++ b/src/Currency/Currencies/LYDCurrency.php @@ -5,6 +5,11 @@ class LYDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return 'LYD'; diff --git a/src/Currency/Currencies/MADCurrency.php b/src/Currency/Currencies/MADCurrency.php index 8f9cd6e..d59f99c 100644 --- a/src/Currency/Currencies/MADCurrency.php +++ b/src/Currency/Currencies/MADCurrency.php @@ -5,6 +5,11 @@ class MADCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MAD'; diff --git a/src/Currency/Currencies/MDLCurrency.php b/src/Currency/Currencies/MDLCurrency.php index 99300c4..e728b41 100644 --- a/src/Currency/Currencies/MDLCurrency.php +++ b/src/Currency/Currencies/MDLCurrency.php @@ -5,6 +5,11 @@ class MDLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MDL'; diff --git a/src/Currency/Currencies/MGACurrency.php b/src/Currency/Currencies/MGACurrency.php index 1ede7cd..1ba563c 100644 --- a/src/Currency/Currencies/MGACurrency.php +++ b/src/Currency/Currencies/MGACurrency.php @@ -5,6 +5,11 @@ class MGACurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'MGA'; diff --git a/src/Currency/Currencies/MKDCurrency.php b/src/Currency/Currencies/MKDCurrency.php index ad7213f..1806ee6 100644 --- a/src/Currency/Currencies/MKDCurrency.php +++ b/src/Currency/Currencies/MKDCurrency.php @@ -5,6 +5,11 @@ class MKDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ден'; diff --git a/src/Currency/Currencies/MMKCurrency.php b/src/Currency/Currencies/MMKCurrency.php index 9b060b7..5b424e7 100644 --- a/src/Currency/Currencies/MMKCurrency.php +++ b/src/Currency/Currencies/MMKCurrency.php @@ -5,6 +5,11 @@ class MMKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MMK'; diff --git a/src/Currency/Currencies/MNTCurrency.php b/src/Currency/Currencies/MNTCurrency.php index 0a1aff0..2e42fb4 100644 --- a/src/Currency/Currencies/MNTCurrency.php +++ b/src/Currency/Currencies/MNTCurrency.php @@ -5,6 +5,11 @@ class MNTCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₮'; diff --git a/src/Currency/Currencies/MOPCurrency.php b/src/Currency/Currencies/MOPCurrency.php index dd58429..973d506 100644 --- a/src/Currency/Currencies/MOPCurrency.php +++ b/src/Currency/Currencies/MOPCurrency.php @@ -5,6 +5,11 @@ class MOPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MOP'; diff --git a/src/Currency/Currencies/MROCurrency.php b/src/Currency/Currencies/MROCurrency.php index 35b69ca..35912bc 100644 --- a/src/Currency/Currencies/MROCurrency.php +++ b/src/Currency/Currencies/MROCurrency.php @@ -5,6 +5,11 @@ class MROCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MRO'; diff --git a/src/Currency/Currencies/MTLCurrency.php b/src/Currency/Currencies/MTLCurrency.php index f960a95..5a08c57 100644 --- a/src/Currency/Currencies/MTLCurrency.php +++ b/src/Currency/Currencies/MTLCurrency.php @@ -5,6 +5,11 @@ class MTLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MTL'; diff --git a/src/Currency/Currencies/MURCurrency.php b/src/Currency/Currencies/MURCurrency.php index 69f3796..502ab7b 100644 --- a/src/Currency/Currencies/MURCurrency.php +++ b/src/Currency/Currencies/MURCurrency.php @@ -5,6 +5,11 @@ class MURCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₨'; diff --git a/src/Currency/Currencies/MVRCurrency.php b/src/Currency/Currencies/MVRCurrency.php index bc01314..0aaba54 100644 --- a/src/Currency/Currencies/MVRCurrency.php +++ b/src/Currency/Currencies/MVRCurrency.php @@ -5,6 +5,11 @@ class MVRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MVR'; diff --git a/src/Currency/Currencies/MWKCurrency.php b/src/Currency/Currencies/MWKCurrency.php index 3435713..4c91bdd 100644 --- a/src/Currency/Currencies/MWKCurrency.php +++ b/src/Currency/Currencies/MWKCurrency.php @@ -5,6 +5,11 @@ class MWKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MWK'; diff --git a/src/Currency/Currencies/MXNCurrency.php b/src/Currency/Currencies/MXNCurrency.php index 59e25e3..64b1a5f 100644 --- a/src/Currency/Currencies/MXNCurrency.php +++ b/src/Currency/Currencies/MXNCurrency.php @@ -5,6 +5,11 @@ class MXNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/MYRCurrency.php b/src/Currency/Currencies/MYRCurrency.php index 3004179..8c32eae 100644 --- a/src/Currency/Currencies/MYRCurrency.php +++ b/src/Currency/Currencies/MYRCurrency.php @@ -5,6 +5,11 @@ class MYRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'RM'; diff --git a/src/Currency/Currencies/MZMCurrency.php b/src/Currency/Currencies/MZMCurrency.php index 66d2fc6..882712d 100644 --- a/src/Currency/Currencies/MZMCurrency.php +++ b/src/Currency/Currencies/MZMCurrency.php @@ -5,6 +5,11 @@ class MZMCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'MZM'; diff --git a/src/Currency/Currencies/MZNCurrency.php b/src/Currency/Currencies/MZNCurrency.php index c6598ab..8fcdef8 100644 --- a/src/Currency/Currencies/MZNCurrency.php +++ b/src/Currency/Currencies/MZNCurrency.php @@ -5,6 +5,11 @@ class MZNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'MT'; diff --git a/src/Currency/Currencies/NADCurrency.php b/src/Currency/Currencies/NADCurrency.php index 4d0538c..6cba9eb 100644 --- a/src/Currency/Currencies/NADCurrency.php +++ b/src/Currency/Currencies/NADCurrency.php @@ -5,6 +5,11 @@ class NADCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/NGNCurrency.php b/src/Currency/Currencies/NGNCurrency.php index 2c91646..f362bd9 100644 --- a/src/Currency/Currencies/NGNCurrency.php +++ b/src/Currency/Currencies/NGNCurrency.php @@ -5,6 +5,11 @@ class NGNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₦'; diff --git a/src/Currency/Currencies/NIOCurrency.php b/src/Currency/Currencies/NIOCurrency.php index fce5b92..8863524 100644 --- a/src/Currency/Currencies/NIOCurrency.php +++ b/src/Currency/Currencies/NIOCurrency.php @@ -5,6 +5,11 @@ class NIOCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'C$'; diff --git a/src/Currency/Currencies/NLGCurrency.php b/src/Currency/Currencies/NLGCurrency.php index 2e873da..d5e31f9 100644 --- a/src/Currency/Currencies/NLGCurrency.php +++ b/src/Currency/Currencies/NLGCurrency.php @@ -5,6 +5,11 @@ class NLGCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'NLG'; diff --git a/src/Currency/Currencies/NOKCurrency.php b/src/Currency/Currencies/NOKCurrency.php index c837926..4d9791e 100644 --- a/src/Currency/Currencies/NOKCurrency.php +++ b/src/Currency/Currencies/NOKCurrency.php @@ -5,6 +5,11 @@ class NOKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'kr'; diff --git a/src/Currency/Currencies/NPRCurrency.php b/src/Currency/Currencies/NPRCurrency.php index cd511c0..ea68959 100644 --- a/src/Currency/Currencies/NPRCurrency.php +++ b/src/Currency/Currencies/NPRCurrency.php @@ -5,6 +5,11 @@ class NPRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₨'; diff --git a/src/Currency/Currencies/NZDCurrency.php b/src/Currency/Currencies/NZDCurrency.php index 4455194..625f384 100644 --- a/src/Currency/Currencies/NZDCurrency.php +++ b/src/Currency/Currencies/NZDCurrency.php @@ -5,6 +5,11 @@ class NZDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/OMRCurrency.php b/src/Currency/Currencies/OMRCurrency.php index 7181a66..9b319cc 100644 --- a/src/Currency/Currencies/OMRCurrency.php +++ b/src/Currency/Currencies/OMRCurrency.php @@ -5,6 +5,11 @@ class OMRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return '﷼'; diff --git a/src/Currency/Currencies/PABCurrency.php b/src/Currency/Currencies/PABCurrency.php index 4cd9f85..6958fe5 100644 --- a/src/Currency/Currencies/PABCurrency.php +++ b/src/Currency/Currencies/PABCurrency.php @@ -5,6 +5,11 @@ class PABCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'B/.'; diff --git a/src/Currency/Currencies/PENCurrency.php b/src/Currency/Currencies/PENCurrency.php index 55f20a0..9434c36 100644 --- a/src/Currency/Currencies/PENCurrency.php +++ b/src/Currency/Currencies/PENCurrency.php @@ -5,6 +5,11 @@ class PENCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'S/.'; diff --git a/src/Currency/Currencies/PGKCurrency.php b/src/Currency/Currencies/PGKCurrency.php index 2e5ddae..7d62f72 100644 --- a/src/Currency/Currencies/PGKCurrency.php +++ b/src/Currency/Currencies/PGKCurrency.php @@ -5,6 +5,11 @@ class PGKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'PGK'; diff --git a/src/Currency/Currencies/PHPCurrency.php b/src/Currency/Currencies/PHPCurrency.php index af6c213..07d6587 100644 --- a/src/Currency/Currencies/PHPCurrency.php +++ b/src/Currency/Currencies/PHPCurrency.php @@ -5,6 +5,11 @@ class PHPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₱'; diff --git a/src/Currency/Currencies/PKRCurrency.php b/src/Currency/Currencies/PKRCurrency.php index 09393cf..b5f8fdf 100644 --- a/src/Currency/Currencies/PKRCurrency.php +++ b/src/Currency/Currencies/PKRCurrency.php @@ -5,6 +5,11 @@ class PKRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₨'; diff --git a/src/Currency/Currencies/PLNCurrency.php b/src/Currency/Currencies/PLNCurrency.php index b98cfc6..0d4b890 100644 --- a/src/Currency/Currencies/PLNCurrency.php +++ b/src/Currency/Currencies/PLNCurrency.php @@ -5,6 +5,11 @@ class PLNCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'zł'; diff --git a/src/Currency/Currencies/PTECurrency.php b/src/Currency/Currencies/PTECurrency.php index d36fdcb..3a8f4b7 100644 --- a/src/Currency/Currencies/PTECurrency.php +++ b/src/Currency/Currencies/PTECurrency.php @@ -5,6 +5,11 @@ class PTECurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'PTE'; diff --git a/src/Currency/Currencies/PYGCurrency.php b/src/Currency/Currencies/PYGCurrency.php index c2c3f3f..04c7b58 100644 --- a/src/Currency/Currencies/PYGCurrency.php +++ b/src/Currency/Currencies/PYGCurrency.php @@ -5,6 +5,11 @@ class PYGCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'Gs'; diff --git a/src/Currency/Currencies/QARCurrency.php b/src/Currency/Currencies/QARCurrency.php index 5b97c19..3466b38 100644 --- a/src/Currency/Currencies/QARCurrency.php +++ b/src/Currency/Currencies/QARCurrency.php @@ -5,6 +5,11 @@ class QARCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '﷼'; diff --git a/src/Currency/Currencies/ROLCurrency.php b/src/Currency/Currencies/ROLCurrency.php index a5dd324..52c563c 100644 --- a/src/Currency/Currencies/ROLCurrency.php +++ b/src/Currency/Currencies/ROLCurrency.php @@ -5,6 +5,11 @@ class ROLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ROL'; diff --git a/src/Currency/Currencies/RONCurrency.php b/src/Currency/Currencies/RONCurrency.php index d508d06..0529749 100644 --- a/src/Currency/Currencies/RONCurrency.php +++ b/src/Currency/Currencies/RONCurrency.php @@ -5,6 +5,11 @@ class RONCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'lei'; diff --git a/src/Currency/Currencies/RSDCurrency.php b/src/Currency/Currencies/RSDCurrency.php index 172aeef..7281987 100644 --- a/src/Currency/Currencies/RSDCurrency.php +++ b/src/Currency/Currencies/RSDCurrency.php @@ -5,6 +5,11 @@ class RSDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Дин.'; diff --git a/src/Currency/Currencies/RUBCurrency.php b/src/Currency/Currencies/RUBCurrency.php index 888ec3a..9538626 100644 --- a/src/Currency/Currencies/RUBCurrency.php +++ b/src/Currency/Currencies/RUBCurrency.php @@ -5,6 +5,11 @@ class RUBCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'руб'; diff --git a/src/Currency/Currencies/RWFCurrency.php b/src/Currency/Currencies/RWFCurrency.php index e316eee..afae632 100644 --- a/src/Currency/Currencies/RWFCurrency.php +++ b/src/Currency/Currencies/RWFCurrency.php @@ -5,6 +5,11 @@ class RWFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'RWF'; diff --git a/src/Currency/Currencies/SARCurrency.php b/src/Currency/Currencies/SARCurrency.php index f3e9714..b03232b 100644 --- a/src/Currency/Currencies/SARCurrency.php +++ b/src/Currency/Currencies/SARCurrency.php @@ -5,6 +5,11 @@ class SARCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '﷼'; diff --git a/src/Currency/Currencies/SBDCurrency.php b/src/Currency/Currencies/SBDCurrency.php index 260247e..04563e0 100644 --- a/src/Currency/Currencies/SBDCurrency.php +++ b/src/Currency/Currencies/SBDCurrency.php @@ -5,6 +5,11 @@ class SBDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/SCRCurrency.php b/src/Currency/Currencies/SCRCurrency.php index 34040ca..2bcbbaf 100644 --- a/src/Currency/Currencies/SCRCurrency.php +++ b/src/Currency/Currencies/SCRCurrency.php @@ -5,6 +5,11 @@ class SCRCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₨'; diff --git a/src/Currency/Currencies/SDDCurrency.php b/src/Currency/Currencies/SDDCurrency.php index d0a2f44..a440940 100644 --- a/src/Currency/Currencies/SDDCurrency.php +++ b/src/Currency/Currencies/SDDCurrency.php @@ -5,6 +5,11 @@ class SDDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'SDD'; diff --git a/src/Currency/Currencies/SEKCurrency.php b/src/Currency/Currencies/SEKCurrency.php index 884008b..e79f14e 100644 --- a/src/Currency/Currencies/SEKCurrency.php +++ b/src/Currency/Currencies/SEKCurrency.php @@ -5,6 +5,11 @@ class SEKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'kr'; diff --git a/src/Currency/Currencies/SGDCurrency.php b/src/Currency/Currencies/SGDCurrency.php index 272b3cb..8c28e61 100644 --- a/src/Currency/Currencies/SGDCurrency.php +++ b/src/Currency/Currencies/SGDCurrency.php @@ -5,6 +5,11 @@ class SGDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/SHPCurrency.php b/src/Currency/Currencies/SHPCurrency.php index 972dcfd..b125cd7 100644 --- a/src/Currency/Currencies/SHPCurrency.php +++ b/src/Currency/Currencies/SHPCurrency.php @@ -5,6 +5,11 @@ class SHPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/SITCurrency.php b/src/Currency/Currencies/SITCurrency.php index 466bcd4..b34526c 100644 --- a/src/Currency/Currencies/SITCurrency.php +++ b/src/Currency/Currencies/SITCurrency.php @@ -5,6 +5,11 @@ class SITCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'SIT'; diff --git a/src/Currency/Currencies/SKKCurrency.php b/src/Currency/Currencies/SKKCurrency.php index 6b73561..a7c9077 100644 --- a/src/Currency/Currencies/SKKCurrency.php +++ b/src/Currency/Currencies/SKKCurrency.php @@ -5,6 +5,11 @@ class SKKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'SKK'; diff --git a/src/Currency/Currencies/SLLCurrency.php b/src/Currency/Currencies/SLLCurrency.php index ca25c59..086c36a 100644 --- a/src/Currency/Currencies/SLLCurrency.php +++ b/src/Currency/Currencies/SLLCurrency.php @@ -5,6 +5,11 @@ class SLLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'SLL'; diff --git a/src/Currency/Currencies/SOSCurrency.php b/src/Currency/Currencies/SOSCurrency.php index ace4b02..8be6961 100644 --- a/src/Currency/Currencies/SOSCurrency.php +++ b/src/Currency/Currencies/SOSCurrency.php @@ -5,6 +5,11 @@ class SOSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'S'; diff --git a/src/Currency/Currencies/SRDCurrency.php b/src/Currency/Currencies/SRDCurrency.php index ff87179..621e21b 100644 --- a/src/Currency/Currencies/SRDCurrency.php +++ b/src/Currency/Currencies/SRDCurrency.php @@ -5,6 +5,11 @@ class SRDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/STDCurrency.php b/src/Currency/Currencies/STDCurrency.php index fd4d1a0..1273be1 100644 --- a/src/Currency/Currencies/STDCurrency.php +++ b/src/Currency/Currencies/STDCurrency.php @@ -5,6 +5,11 @@ class STDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'STD'; diff --git a/src/Currency/Currencies/SVCCurrency.php b/src/Currency/Currencies/SVCCurrency.php index e1c8a43..6c037dc 100644 --- a/src/Currency/Currencies/SVCCurrency.php +++ b/src/Currency/Currencies/SVCCurrency.php @@ -5,6 +5,11 @@ class SVCCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/SYPCurrency.php b/src/Currency/Currencies/SYPCurrency.php index 100801e..40332b1 100644 --- a/src/Currency/Currencies/SYPCurrency.php +++ b/src/Currency/Currencies/SYPCurrency.php @@ -5,6 +5,11 @@ class SYPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '£'; diff --git a/src/Currency/Currencies/SZLCurrency.php b/src/Currency/Currencies/SZLCurrency.php index 9416e16..f73949d 100644 --- a/src/Currency/Currencies/SZLCurrency.php +++ b/src/Currency/Currencies/SZLCurrency.php @@ -5,6 +5,11 @@ class SZLCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'SZL'; diff --git a/src/Currency/Currencies/THBCurrency.php b/src/Currency/Currencies/THBCurrency.php index e7c290c..ee1bb37 100644 --- a/src/Currency/Currencies/THBCurrency.php +++ b/src/Currency/Currencies/THBCurrency.php @@ -5,6 +5,11 @@ class THBCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '฿'; diff --git a/src/Currency/Currencies/TJSCurrency.php b/src/Currency/Currencies/TJSCurrency.php index 00c186e..dc43ebe 100644 --- a/src/Currency/Currencies/TJSCurrency.php +++ b/src/Currency/Currencies/TJSCurrency.php @@ -5,6 +5,11 @@ class TJSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return  ; + } + public function getSymbol() { return 'TJS'; diff --git a/src/Currency/Currencies/TMMCurrency.php b/src/Currency/Currencies/TMMCurrency.php index 9598598..0cb7693 100644 --- a/src/Currency/Currencies/TMMCurrency.php +++ b/src/Currency/Currencies/TMMCurrency.php @@ -5,6 +5,11 @@ class TMMCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'TMM'; diff --git a/src/Currency/Currencies/TMTCurrency.php b/src/Currency/Currencies/TMTCurrency.php index d6b022b..61eef1b 100644 --- a/src/Currency/Currencies/TMTCurrency.php +++ b/src/Currency/Currencies/TMTCurrency.php @@ -5,6 +5,11 @@ class TMTCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'TMT'; diff --git a/src/Currency/Currencies/TNDCurrency.php b/src/Currency/Currencies/TNDCurrency.php index 25ed23a..e920514 100644 --- a/src/Currency/Currencies/TNDCurrency.php +++ b/src/Currency/Currencies/TNDCurrency.php @@ -5,6 +5,11 @@ class TNDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 3; + } + public function getSymbol() { return 'TND'; diff --git a/src/Currency/Currencies/TOPCurrency.php b/src/Currency/Currencies/TOPCurrency.php index d4b0f00..27f6753 100644 --- a/src/Currency/Currencies/TOPCurrency.php +++ b/src/Currency/Currencies/TOPCurrency.php @@ -5,6 +5,11 @@ class TOPCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'TOP'; diff --git a/src/Currency/Currencies/TRYCurrency.php b/src/Currency/Currencies/TRYCurrency.php index 478f1cb..9d4942e 100644 --- a/src/Currency/Currencies/TRYCurrency.php +++ b/src/Currency/Currencies/TRYCurrency.php @@ -5,6 +5,11 @@ class TRYCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return ''; diff --git a/src/Currency/Currencies/TTDCurrency.php b/src/Currency/Currencies/TTDCurrency.php index 1651b7f..1d900b2 100644 --- a/src/Currency/Currencies/TTDCurrency.php +++ b/src/Currency/Currencies/TTDCurrency.php @@ -5,6 +5,11 @@ class TTDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'TT$'; diff --git a/src/Currency/Currencies/TWDCurrency.php b/src/Currency/Currencies/TWDCurrency.php index 44aec42..63ccda7 100644 --- a/src/Currency/Currencies/TWDCurrency.php +++ b/src/Currency/Currencies/TWDCurrency.php @@ -5,6 +5,11 @@ class TWDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'NT$'; diff --git a/src/Currency/Currencies/TZSCurrency.php b/src/Currency/Currencies/TZSCurrency.php index d8ab943..07275db 100644 --- a/src/Currency/Currencies/TZSCurrency.php +++ b/src/Currency/Currencies/TZSCurrency.php @@ -5,6 +5,11 @@ class TZSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'TZS'; diff --git a/src/Currency/Currencies/UAHCurrency.php b/src/Currency/Currencies/UAHCurrency.php index fd8c659..446269e 100644 --- a/src/Currency/Currencies/UAHCurrency.php +++ b/src/Currency/Currencies/UAHCurrency.php @@ -5,6 +5,11 @@ class UAHCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₴'; diff --git a/src/Currency/Currencies/UGXCurrency.php b/src/Currency/Currencies/UGXCurrency.php index dafd222..592411d 100644 --- a/src/Currency/Currencies/UGXCurrency.php +++ b/src/Currency/Currencies/UGXCurrency.php @@ -5,6 +5,11 @@ class UGXCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'UGX'; diff --git a/src/Currency/Currencies/USDCurrency.php b/src/Currency/Currencies/USDCurrency.php index 052c62f..5d919d9 100644 --- a/src/Currency/Currencies/USDCurrency.php +++ b/src/Currency/Currencies/USDCurrency.php @@ -5,6 +5,11 @@ class USDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/UYUCurrency.php b/src/Currency/Currencies/UYUCurrency.php index 2eb6e17..db49bb5 100644 --- a/src/Currency/Currencies/UYUCurrency.php +++ b/src/Currency/Currencies/UYUCurrency.php @@ -5,6 +5,11 @@ class UYUCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$U'; diff --git a/src/Currency/Currencies/UZSCurrency.php b/src/Currency/Currencies/UZSCurrency.php index 2ea83ab..73785d3 100644 --- a/src/Currency/Currencies/UZSCurrency.php +++ b/src/Currency/Currencies/UZSCurrency.php @@ -5,6 +5,11 @@ class UZSCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'лв'; diff --git a/src/Currency/Currencies/VEFCurrency.php b/src/Currency/Currencies/VEFCurrency.php index f4a9b0c..1221a94 100644 --- a/src/Currency/Currencies/VEFCurrency.php +++ b/src/Currency/Currencies/VEFCurrency.php @@ -5,6 +5,11 @@ class VEFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Bs'; diff --git a/src/Currency/Currencies/VNDCurrency.php b/src/Currency/Currencies/VNDCurrency.php index bb9c6d0..b422df7 100644 --- a/src/Currency/Currencies/VNDCurrency.php +++ b/src/Currency/Currencies/VNDCurrency.php @@ -5,6 +5,11 @@ class VNDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '₫'; diff --git a/src/Currency/Currencies/VUVCurrency.php b/src/Currency/Currencies/VUVCurrency.php index cdb7638..4b120eb 100644 --- a/src/Currency/Currencies/VUVCurrency.php +++ b/src/Currency/Currencies/VUVCurrency.php @@ -5,6 +5,11 @@ class VUVCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'VUV'; diff --git a/src/Currency/Currencies/WSTCurrency.php b/src/Currency/Currencies/WSTCurrency.php index 43eb913..6c5ef66 100644 --- a/src/Currency/Currencies/WSTCurrency.php +++ b/src/Currency/Currencies/WSTCurrency.php @@ -5,6 +5,11 @@ class WSTCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'WST'; diff --git a/src/Currency/Currencies/XCDCurrency.php b/src/Currency/Currencies/XCDCurrency.php index ef398b2..5d73b2a 100644 --- a/src/Currency/Currencies/XCDCurrency.php +++ b/src/Currency/Currencies/XCDCurrency.php @@ -5,6 +5,11 @@ class XCDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '$'; diff --git a/src/Currency/Currencies/XPFCurrency.php b/src/Currency/Currencies/XPFCurrency.php index 168b648..e6b022b 100644 --- a/src/Currency/Currencies/XPFCurrency.php +++ b/src/Currency/Currencies/XPFCurrency.php @@ -5,6 +5,11 @@ class XPFCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 0; + } + public function getSymbol() { return 'CFPF'; diff --git a/src/Currency/Currencies/YERCurrency.php b/src/Currency/Currencies/YERCurrency.php index 7397270..27e1738 100644 --- a/src/Currency/Currencies/YERCurrency.php +++ b/src/Currency/Currencies/YERCurrency.php @@ -5,6 +5,11 @@ class YERCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return '﷼'; diff --git a/src/Currency/Currencies/ZARCurrency.php b/src/Currency/Currencies/ZARCurrency.php index 84a0132..ca84090 100644 --- a/src/Currency/Currencies/ZARCurrency.php +++ b/src/Currency/Currencies/ZARCurrency.php @@ -5,6 +5,11 @@ class ZARCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'R'; diff --git a/src/Currency/Currencies/ZMKCurrency.php b/src/Currency/Currencies/ZMKCurrency.php index a746a61..26f2f33 100644 --- a/src/Currency/Currencies/ZMKCurrency.php +++ b/src/Currency/Currencies/ZMKCurrency.php @@ -5,6 +5,11 @@ class ZMKCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ZMK'; diff --git a/src/Currency/Currencies/ZMWCurrency.php b/src/Currency/Currencies/ZMWCurrency.php index 83a7040..b3a991b 100644 --- a/src/Currency/Currencies/ZMWCurrency.php +++ b/src/Currency/Currencies/ZMWCurrency.php @@ -5,6 +5,11 @@ class ZMWCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'ZMW'; diff --git a/src/Currency/Currencies/ZWDCurrency.php b/src/Currency/Currencies/ZWDCurrency.php index 09121be..c898429 100644 --- a/src/Currency/Currencies/ZWDCurrency.php +++ b/src/Currency/Currencies/ZWDCurrency.php @@ -5,6 +5,11 @@ class ZWDCurrency extends AbstractCurrency { + public function getDecimalCount() + { + return 2; + } + public function getSymbol() { return 'Z$'; diff --git a/src/Currency/Currencies/build/csv.php b/src/Currency/Currencies/build/csv.php index 934b2a9..5364269 100644 --- a/src/Currency/Currencies/build/csv.php +++ b/src/Currency/Currencies/build/csv.php @@ -7,6 +7,11 @@ class {{alpha}}Currency extends AbstractCurrency { + public function getDecimalCount() + { + return {{decimal}}; + } + public function getSymbol() { return \'{{symbol}}\'; diff --git a/tests/Currency/CurrencyTest.php b/tests/Currency/CurrencyTest.php index d7f8aeb..0adf919 100644 --- a/tests/Currency/CurrencyTest.php +++ b/tests/Currency/CurrencyTest.php @@ -15,4 +15,13 @@ public function testUsdCurrencyValue() $this->assertEquals(1, $jpy->getUSDAverageValue($jpy->getUSDAverage())); $this->assertEquals(1.994, $jpy->getUSDAverageValue(200), '', 0.001); } + + public function testCurrencyFormat() + { + $gbp = CurrencyHelper::getCurrency('GBP'); + $this->assertEquals('£123.00', $gbp->format(123)); + + $jpy = CurrencyHelper::getCurrency('JPY'); + $this->assertEquals('¥123', $jpy->format(123)); + } }