pub trait ConfigProviderExt: ConfigProvider {
// Provided methods
fn get<T: DeserializeOwned + Send>(
&self,
key: &str,
) -> impl Future<Output = ConfigResult<Option<T>>> + Send
where Self: Sync { ... }
fn set<T: Serialize + Send + Sync>(
&self,
key: &str,
value: &T,
) -> impl Future<Output = ConfigResult<()>> + Send
where Self: Sync { ... }
}Expand description
Extension methods for typed configuration access
Provided Methods§
Sourcefn get<T: DeserializeOwned + Send>(
&self,
key: &str,
) -> impl Future<Output = ConfigResult<Option<T>>> + Sendwhere
Self: Sync,
fn get<T: DeserializeOwned + Send>(
&self,
key: &str,
) -> impl Future<Output = ConfigResult<Option<T>>> + Sendwhere
Self: Sync,
Get a typed configuration value
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.