use chrono::NaiveDate;
pub trait DayCountConvention {
fn year_fraction(&self, start: NaiveDate, end: NaiveDate) -> f64;
fn year_fraction_with_maturity(
&self,
start: NaiveDate,
end: NaiveDate,
frequencency: i32,
maturity: NaiveDate,
) -> f64 {
self.year_fraction(start, end)
}
fn day_count(&self, start: NaiveDate, end: NaiveDate) -> i32;
}