8#ifndef INCLUDED_BBLDC_PERIODDAYCOUNTUTIL
9#define INCLUDED_BBLDC_PERIODDAYCOUNTUTIL
105#include <bblscm_version.h>
113#include <bsl_vector.h>
148 static double yearsDiffImp(
const bdlt::Date& beginDate,
152 double periodYearDiff,
172 double periodYearDiff,
178 const std::vector<bdlt::Date>& periodDate,
179 double periodYearDiff,
181#ifdef BSLS_LIBRARYFEATURES_HAS_CPP17_PMR
184 const std::pmr::vector<bdlt::Date>& periodDate,
185 double periodYearDiff,
219 double periodYearDiff,
222 return yearsDiffImp(beginDate,
225 periodDate.
data() + periodDate.
size(),
234 const std::vector<bdlt::Date>& periodDate,
235 double periodYearDiff,
241 const bdlt::Date *begin = periodDate.empty() ? 0 : &*periodDate.begin();
242 const bdlt::Date *end = begin + periodDate.size();
244 return yearsDiffImp(beginDate,
252#ifdef BSLS_LIBRARYFEATURES_HAS_CPP17_PMR
257 const std::pmr::vector<bdlt::Date>& periodDate,
258 double periodYearDiff,
264 return yearsDiffImp(beginDate,
267 periodDate.data() + periodDate.size(),
Definition bdlt_date.h:294
size_type size() const BSLS_KEYWORD_NOEXCEPT
Return the number of elements in this vector.
Definition bslstl_vector.h:2664
VALUE_TYPE * data() BSLS_KEYWORD_NOEXCEPT
Definition bslstl_vector.h:2587
Definition bslstl_vector.h:1025
#define BSLS_IDENT(str)
Definition bsls_ident.h:195
Definition bbldc_basicactual360.h:107
Enum
Definition bbldc_daycountconvention.h:131
Definition bbldc_perioddaycountutil.h:127
static bool isSupported(DayCountConvention::Enum convention)
static double yearsDiff(const bdlt::Date &beginDate, const bdlt::Date &endDate, const bsl::vector< bdlt::Date > &periodDate, double periodYearDiff, DayCountConvention::Enum convention)
Definition bbldc_perioddaycountutil.h:215
static int daysDiff(const bdlt::Date &beginDate, const bdlt::Date &endDate, DayCountConvention::Enum convention)