pub trait ResourceLoader {
// Provided method
fn load<'life0, 'async_trait>(
source: &'life0 str,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
where Self: Sized + DeserializeOwned + Send + 'async_trait,
'life0: 'async_trait { ... }
}Expand description
Load config from local file or remote url. To use this trait, derive DeserializeOwned then implement this trait.
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".