Skip to main content

ical/component/
vtimezone.rs

1//! # VTIMEZONE
2//!
3//! The `VTIMEZONE` component: a time zone, carrying its own transition rules
4//! (RFC 5545 3.6.5).
5
6use crate::{
7    component::{IcalComponentKind, spec::IcalComponentSpec},
8    prop::IcalPropKind,
9};
10
11/// The `VTIMEZONE` component marker.
12pub struct VTIMEZONE;
13
14impl IcalComponentSpec for VTIMEZONE {
15    const KIND: IcalComponentKind = IcalComponentKind::VTimezone;
16
17    fn allowed_children() -> &'static [IcalComponentKind] {
18        &[IcalComponentKind::Standard, IcalComponentKind::Daylight]
19    }
20
21    fn required_props() -> &'static [IcalPropKind] {
22        &[IcalPropKind::TzId]
23    }
24}