BloombergLP::bbldc::PeriodIcmaActualActual::yearsDiff

Return the signed fractional year count between two dates.

Synopsis

Declared in <bbldc_periodicmaactualactual.h>

static
double
yearsDiff(
    bdlt::Date const& beginDate,
    bdlt::Date const& endDate,
    bdlt::Date const* periodDateBegin,
    bdlt::Date const* periodDateEnd,
    double periodYearDiff);

Return Value

the signed fractional number of years between the dates

Parameters

NameDescription
beginDatethe start date
endDatethe end date
periodDateBeginthe first period boundary date
periodDateEndone past the last period boundary date
periodYearDiffthe duration of each period in years