Skip to main content

fx

Function fx 

Source
pub fn fx(
    amount: Decimal,
    from: &str,
    to: &str,
    rates: &[Value],
    table: &str,
    scale: u32,
) -> Result<Decimal, Fault>
Expand description

amount / rate(from) * rate(to), each step half-even at 10^-9, then rescaled half-even to scale (fx_convert@1).