Converter
in package
FinalYes
Конвертация суммы по курсу и отдельный путь округления до шага наличных.
Table of Contents
Properties
Methods
- __construct() : mixed
- convert() : Money
- convertCash() : Money
- Конвертация с последующим округлением до cash-шага валюты назначения.
Properties
$math read-only
private
IntegerMath
$math
Methods
__construct()
public
__construct(IntegerMath $math) : mixed
Parameters
- $math : IntegerMath
convert()
public
convert(Money $money, Currency $quote, ExchangeRate $rate, RoundingMode $mode) : Money
Parameters
- $money : Money
- $quote : Currency
- $rate : ExchangeRate
- $mode : RoundingMode
Tags
Return values
MoneyconvertCash()
Конвертация с последующим округлением до cash-шага валюты назначения.
public
convertCash(Money $money, Currency $quote, ExchangeRate $rate, RoundingMode $mode) : Money
Parameters
- $money : Money
- $quote : Currency
- $rate : ExchangeRate
- $mode : RoundingMode