simple_time_zone_rule


Represents a simple rule used to determine daylight savings time (dst) adjustments.

Library

Time<ToolKit>

Declaration

#include <ospace/time/simple.h>

class os_simple_time_zone_rule : public os_time_zone_rule

Interface

Constructor
os_simple_time_zone_rule( const os_calendar_date& start_point , const os_calendar_date& end_point , os_year_t start_year , os_year_t end_year )
Constructs a dst rule that is valid from start_point in the year start_year through end_point in the year end_year . Assume a sixty-minute dst adjustment value.
Constructor
os_simple_time_zone_rule( const os_calendar_date& start_point , const os_calendar_date& end_point , os_year_t start_year , os_year_t end_year , const os_time_period& adjustment )
Constructs a dst rule that is valid from start_point in the year start_year through end_point in the year end_year . When dst is in effect, the time is corrected by an adjustment time period.
is_in_effect
/* virtual */ bool is_in_effect( const os_time& time , const os_date& date , bool std_time ) const
Returns true if this rule is in effect on date at time , where std_time is true if representation is standard and false if representation is local.

Throws: os_time_toolkit_error


Copyright©1994-2026 Recursion Software LLC
All Rights Reserved - For use by licensed users only.