Template Class FlexibleSchedule

Inheritance Relationships

Base Type

Class Documentation

template<typename T>
class FlexibleSchedule : public otyca::Schedule<std::pair<boost::posix_time::time_duration, T>>

A schedule that associates a value with a flexible time duration.

This class extends Schedule and allows each value to be associated with a time duration, offering the ability to convert into a BoundedSchedule where each entry is bounded by its duration.

Template Parameters:

T – The type of the values stored in the schedule.

Public Functions

inline std::shared_ptr<BoundedSchedule<T>> to_bounded_schedule() const

Converts the flexible schedule into a bounded schedule.

Each entry in the flexible schedule is transformed into a bounded range by subtracting and adding the duration from the key, forming an interval.

Returns:

A shared pointer to the resulting BoundedSchedule<T>.