ical/prop/dtstart.rs
1//! # DTSTART
2//!
3//! The `DTSTART` property: when the component starts, and the clock a
4//! recurrence expands on (RFC 5545 3.8.2.4).
5
6use crate::{
7 prop::{IcalPropKind, cardinality::IcalPropCardinality, spec::IcalPropSpec},
8 value::IcalValueKind,
9 version::IcalVersion,
10};
11
12/// The `DTSTART` property marker.
13pub struct DTSTART;
14
15impl IcalPropSpec for DTSTART {
16 const KIND: IcalPropKind = IcalPropKind::DtStart;
17
18 fn cardinality(_version: IcalVersion) -> IcalPropCardinality {
19 IcalPropCardinality::AtMostOne
20 }
21
22 fn allowed_values(_version: IcalVersion) -> &'static [IcalValueKind] {
23 &[IcalValueKind::DateTime]
24 }
25}