<kiyosi/market/schedule.hpp>
cpp
#include <kiyosi/market/schedule.hpp>validate_date_schedule
cpp
Result<void> kiyosi::validate_date_schedule(std::span<const Date> observation_dates, Date instrument_start, Date instrument_end)Validates ordering and instrument-life bounds for a date schedule. 返回值: Success, or invalid_date, invalid_time_range, or invalid_schedule.
validate_observation_dates
cpp
Result<void> kiyosi::validate_observation_dates(std::span<const Date> observation_dates, Date instrument_start, Date instrument_end, const TradingCalendar &calendar)Validates ordering, life bounds, and trading-day status for observation dates. 返回值: Success, or invalid_date, invalid_time_range, or invalid_schedule.
kiyosi::ObservationSchedule
cpp
class kiyosi::ObservationScheduleImmutable, strictly ordered collection of contract observation dates.
成员
dates
cpp
const std::vector<Date> & kiyosi::ObservationSchedule::dates() const noexceptReturns the underlying ordered dates.
size
cpp
std::size_t kiyosi::ObservationSchedule::size() const noexceptReturns the number of dates.
empty
cpp
bool kiyosi::ObservationSchedule::empty() const noexceptReturns whether the schedule has no dates.
operator[]
cpp
const Date & kiyosi::ObservationSchedule::operator[](std::size_t index) const noexceptReturns the date at index without bounds checking.
begin
cpp
auto kiyosi::ObservationSchedule::begin() const noexceptReturns an iterator to the first date.
end
cpp
auto kiyosi::ObservationSchedule::end() const noexceptReturns the past-the-end iterator.