renvar/
lib.rs

1#![doc = include_str!("docs/crate.md")]
2#![cfg_attr(docsrs, feature(doc_cfg))]
3#![allow(rustdoc::broken_intra_doc_links)]
4#![deny(
5    missing_debug_implementations,
6    missing_docs,
7    clippy::missing_errors_doc,
8    clippy::wrong_self_convention,
9    rustdoc::invalid_rust_codeblocks
10)]
11
12#[cfg(feature = "prefixed")]
13mod prefixed;
14#[cfg(feature = "case_insensitive_prefixed")]
15mod case_insensitive_prefixed;
16#[cfg(feature = "postfixed")]
17mod postfixed;
18#[cfg(feature = "case_insensitive_postfixed")]
19mod case_insensitive_postfixed;
20mod error;
21mod sanitize;
22mod convert;
23
24pub mod de;
25
26pub(crate) mod proc_macros;
27
28////////////////////////////////////////////////////////////////////////////////////////////////////////
29
30pub use convert::{from_env, from_iter, from_os_env, from_str};
31
32#[cfg(feature = "prefixed")]
33pub use prefixed::{prefixed, Prefixed};
34
35#[cfg(feature = "case_insensitive_prefixed")]
36pub use case_insensitive_prefixed::{
37    case_insensitive_prefixed, CaseInsensitivePrefixed,
38};
39#[cfg(feature = "postfixed")]
40pub use postfixed::{postfixed, Postfixed};
41
42#[cfg(feature = "case_insensitive_prefixed")]
43pub use case_insensitive_postfixed::{
44    case_insensitive_postfixed, CaseInsensitivePostfixed,
45};
46
47#[cfg(feature = "with_trimmer")]
48pub use convert::with_trimmer::{
49    from_env_with_trimmer, from_iter_with_trimmer, from_os_env_with_trimmer,
50};
51
52////////////////////////////////////////////////////////////////////////////////////////////////////////
53
54pub use error::Error;
55
56////////////////////////////////////////////////////////////////////////////////////////////////////////
57
58/// `Result` type alias used by this crate
59pub type Result<T> = std::result::Result<T, Error>;