Added new Money provider
This commit is contained in:
@ -13,4 +13,5 @@ interface Provider
|
||||
* @throws EmptyResponse
|
||||
*/
|
||||
public function get(string $money_symbol, ?DateTimeInterface $dateTime = null): float;
|
||||
public function supported(string $money_symbol): bool;
|
||||
}
|
||||
|
||||
13
app/common/Ideal/Money/Provider.php
Normal file
13
app/common/Ideal/Money/Provider.php
Normal file
@ -0,0 +1,13 @@
|
||||
<?php
|
||||
namespace Incoviba\Common\Ideal\Money;
|
||||
|
||||
use Incoviba\Common\Define;
|
||||
|
||||
abstract class Provider implements Define\Money\Provider
|
||||
{
|
||||
protected array $supportedMap = [];
|
||||
public function supported(string $money_symbol): bool
|
||||
{
|
||||
return in_array(strtolower($money_symbol), array_keys($this->supportedMap), true);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user