2023-07-02 00:07:15 +01:00
|
|
|
#![deny(missing_docs)]
|
2018-10-29 01:36:58 +00:00
|
|
|
//! # aerosol
|
|
|
|
|
//! Simple dependency injection for Rust
|
2020-06-02 12:17:59 +01:00
|
|
|
//!
|
2023-07-02 14:02:34 +01:00
|
|
|
//! Optional features:
|
2020-06-02 12:17:59 +01:00
|
|
|
//!
|
2023-07-02 00:07:15 +01:00
|
|
|
//! ## `async`
|
2020-06-02 12:17:59 +01:00
|
|
|
//!
|
2023-07-02 14:02:34 +01:00
|
|
|
//! Allows resources to be constructed asynchrously, and provides a corresponding
|
2023-07-02 00:07:15 +01:00
|
|
|
//! `AsyncConstructibleResource` trait.
|
2020-06-02 12:17:59 +01:00
|
|
|
//!
|
2023-07-02 00:07:15 +01:00
|
|
|
//! ## `axum`
|
2020-06-02 12:17:59 +01:00
|
|
|
//!
|
2023-07-02 14:02:34 +01:00
|
|
|
//! Provides integrations with the `axum` web framework. See the `axum` module
|
2023-07-02 00:07:15 +01:00
|
|
|
//! for more information.
|
2023-08-03 19:56:48 +01:00
|
|
|
pub use frunk;
|
2018-09-18 11:39:15 +01:00
|
|
|
|
2023-07-02 00:07:15 +01:00
|
|
|
#[cfg(feature = "async")]
|
|
|
|
|
mod async_;
|
|
|
|
|
#[cfg(feature = "async")]
|
|
|
|
|
mod async_constructible;
|
|
|
|
|
#[cfg(feature = "axum")]
|
|
|
|
|
pub mod axum;
|
2023-08-03 19:56:48 +01:00
|
|
|
mod macros;
|
2023-07-02 00:07:15 +01:00
|
|
|
mod resource;
|
|
|
|
|
mod slot;
|
|
|
|
|
mod state;
|
|
|
|
|
mod sync;
|
|
|
|
|
mod sync_constructible;
|
2018-09-18 11:39:15 +01:00
|
|
|
|
2023-07-02 00:07:15 +01:00
|
|
|
pub use resource::Resource;
|
|
|
|
|
pub use state::Aerosol;
|
2018-09-18 11:39:15 +01:00
|
|
|
|
2023-07-02 14:30:50 +01:00
|
|
|
pub use sync_constructible::{Constructible, ConstructibleResource, IndirectlyConstructible};
|
2018-09-18 11:39:15 +01:00
|
|
|
|
2023-07-02 00:07:15 +01:00
|
|
|
#[cfg(feature = "async")]
|
2023-07-02 14:30:50 +01:00
|
|
|
pub use async_constructible::{
|
|
|
|
|
AsyncConstructible, AsyncConstructibleResource, IndirectlyAsyncConstructible,
|
|
|
|
|
};
|