fn new(
        std: LocalTimeType,
        dst: LocalTimeType,
        dst_start: RuleDay,
        dst_start_time: i32,
        dst_end: RuleDay,
        dst_end_time: i32,
    ) -> Result<Self, Error> {
        // Overflow is not possible
        if !((dst_start_time as i64).abs() < SECONDS_PER_WEEK
            && (dst_end_time as i64).abs() < SECONDS_PER_WEEK)
        {
            return Err(Error::TransitionRule("invalid DST start or end time"));
        }

        Ok(Self { std, dst, dst_start, dst_start_time, dst_end, dst_end_time })
    }
/// Construct a transition rule representing alternate local time types
Construct a transition rule representing alternate local time types
Construct a transition rule representing alternate local time types
fn new(
        std: LocalTimeType,
        dst: LocalTimeType,
        dst_start: RuleDay,
        dst_start_time: i32,
        dst_end: RuleDay,
        dst_end_time: i32,
    ) -> Result<Self, Error> {
        // Overflow is not possible
        if !((dst_start_time as i64).abs() < SECONDS_PER_WEEK
            && (dst_end_time as i64).abs() < SECONDS_PER_WEEK)
        {
            return Err(Error::TransitionRule("invalid DST start or end time"));
        }
        Ok(Self { std, dst, dst_start, dst_start_time, dst_end, dst_end_time })
    }
fn new ( std : LocalTimeType , dst : LocalTimeType , dst_start : RuleDay , dst_start_time : i32 , dst_end : RuleDay , dst_end_time : i32 , ) -> Result < Self , Error > { // Overflow is not possible if ! ( ( dst_start_time as i64 ) . abs ( ) < SECONDS_PER_WEEK && ( dst_end_time as i64 ) . abs ( ) < SECONDS_PER_WEEK ) { return Err ( Error :: TransitionRule ( " " ) ) ; } Ok ( Self { std , dst , dst_start , dst_start_time , dst_end , dst_end_time } ) }
Construct a transition rule representing alternate local time types
Construct a transition rule representing alternate local time types
std
LocalTimeType
dst
LocalTimeType
dst_start
RuleDay
dst_start_time
i32
dst_end
RuleDay
dst_end_time
i32
std
LocalTimeType
dst
LocalTimeType
dst_start
RuleDay
dst_start_time
i32
dst_end
RuleDay
dst_end_time
i32