icu_time/
lib.rs

1// This file is part of ICU4X. For terms of use, please see the file
2// called LICENSE at the top level of the ICU4X source tree
3// (online at: https://github.com/unicode-org/icu4x/blob/main/LICENSE ).
4
5// https://github.com/unicode-org/icu4x/blob/main/documents/process/boilerplate.md#library-annotations
6#![cfg_attr(not(any(test, doc)), no_std)]
7#![cfg_attr(
8    not(test),
9    deny(
10        clippy::indexing_slicing,
11        clippy::unwrap_used,
12        clippy::expect_used,
13        clippy::panic,
14        clippy::exhaustive_structs,
15        clippy::exhaustive_enums,
16        clippy::trivially_copy_pass_by_ref,
17        missing_debug_implementations,
18    )
19)]
20#![warn(missing_docs)]
21
22//! Time and timezone functionality.
23//!
24//! This module is published as its own crate ([`icu_time`](https://docs.rs/icu_time/latest/icu_time/))
25//! and as part of the [`icu`](https://docs.rs/icu/latest/icu/) crate. See the latter for more details on the ICU4X project.
26
27#[cfg(feature = "alloc")]
28extern crate alloc;
29
30pub mod provider;
31pub mod scaffold;
32
33#[cfg(feature = "ixdtf")]
34mod ixdtf;
35#[cfg(feature = "ixdtf")]
36pub use ixdtf::ParseError;
37
38pub mod zone;
39#[doc(no_inline)]
40pub use zone::{TimeZone, TimeZoneInfo};
41
42mod types;
43pub use types::{DateTime, Hour, Minute, Nanosecond, Second, Time, ZonedDateTime};