Skip to main content

fpml_complete

Function fpml_complete 

pub(crate) fn fpml_complete(
    py: Python<'_>,
    text: &str,
    market: &PyMarket,
) -> PyResult<String>
Expand description

Completes the first trade’s stated cashflows in an FpML 5 confirmation document with their values on market, and returns the document’s text.

Every stated row still owed gains its days, year fraction, rates, forecast amount, discount factor and present value, and every stated principal exchange its discount factor and present value. Nothing else in the text changes. A stream without a cashflows block is left alone. A document the reader refuses, a stream whose stated rows do not pair with the coupons helixio generates, a document already carrying such values, and a market that cannot price the trade raise ValueError naming why.