pub struct Engine<E> { /* private fields */ }Expand description
A wrapper type that implements TemplateEngine for multiple
commonly used engines. See crate::engine for detailed usage instructions
and examples
Implementations§
Trait Implementations§
Source§impl<ApplicationState, E> FromRequestParts<ApplicationState> for Engine<E>
impl<ApplicationState, E> FromRequestParts<ApplicationState> for Engine<E>
Source§type Rejection = Infallible
type Rejection = Infallible
If the extractor fails it’ll use this “rejection” type. A rejection is
a kind of error that can be converted into a response.
Source§async fn from_request_parts(
_: &mut Parts,
state: &ApplicationState,
) -> Result<Self, Self::Rejection>
async fn from_request_parts( _: &mut Parts, state: &ApplicationState, ) -> Result<Self, Self::Rejection>
Perform the extraction.
Source§impl TemplateEngine for Engine<AutoReloader>
Available on crate feature minijinja-autoreload only.
impl TemplateEngine for Engine<AutoReloader>
Available on crate feature
minijinja-autoreload only.Source§impl TemplateEngine for Engine<Environment<'static>>
Available on crate feature minijinja only.
impl TemplateEngine for Engine<Environment<'static>>
Available on crate feature
minijinja only.Source§impl TemplateEngine for Engine<Handlebars<'static>>
impl TemplateEngine for Engine<Handlebars<'static>>
Source§impl TemplateEngine for Engine<Tera>
impl TemplateEngine for Engine<Tera>
impl<E: Eq> Eq for Engine<E>
impl<E> StructuralPartialEq for Engine<E>
Auto Trait Implementations§
impl<E> Freeze for Engine<E>
impl<E> RefUnwindSafe for Engine<E>where
E: RefUnwindSafe,
impl<E> Send for Engine<E>
impl<E> Sync for Engine<E>
impl<E> Unpin for Engine<E>
impl<E> UnsafeUnpin for Engine<E>
impl<E> UnwindSafe for Engine<E>where
E: RefUnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<S, T> FromRequest<S, ViaParts> for T
impl<S, T> FromRequest<S, ViaParts> for T
Source§type Rejection = <T as FromRequestParts<S>>::Rejection
type Rejection = <T as FromRequestParts<S>>::Rejection
If the extractor fails it’ll use this “rejection” type. A rejection is
a kind of error that can be converted into a response.
Source§fn from_request(
req: Request<Body>,
state: &S,
) -> impl Future<Output = Result<T, <T as FromRequest<S, ViaParts>>::Rejection>>
fn from_request( req: Request<Body>, state: &S, ) -> impl Future<Output = Result<T, <T as FromRequest<S, ViaParts>>::Rejection>>
Perform the extraction.