Trait RequestPartsExt

Source
pub trait RequestPartsExt {
    // Required methods
    fn get_app_state(&self) -> &AppState;
    fn get_component<T: Clone + Send + Sync + 'static>(&self) -> Result<T>;
    fn get_config<T: DeserializeOwned + Configurable>(&self) -> Result<T>;
}
Expand description

Extending the functionality of RequestParts

Required Methods§

Source

fn get_app_state(&self) -> &AppState

get AppState

Source

fn get_component<T: Clone + Send + Sync + 'static>(&self) -> Result<T>

get Component

Source

fn get_config<T: DeserializeOwned + Configurable>(&self) -> Result<T>

get Config

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.

Implementations on Foreign Types§

Source§

impl RequestPartsExt for Parts

Implementors§