#[non_exhaustive]pub struct FallbackHandler {
pub linode_api_http_client: LinodeApiHttpClient,
pub version: Version,
}
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.linode_api_http_client: LinodeApiHttpClient
§version: Version
Implementations§
Source§impl FallbackHandler
impl FallbackHandler
pub fn new( linode_api_http_client: LinodeApiHttpClient, version: Version, ) -> Self
Trait Implementations§
Source§impl Clone for FallbackHandler
impl Clone for FallbackHandler
Source§fn clone(&self) -> FallbackHandler
fn clone(&self) -> FallbackHandler
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for FallbackHandler
impl Debug for FallbackHandler
Source§impl<T, S> Handler<T, S> for FallbackHandler
impl<T, S> Handler<T, S> for FallbackHandler
Source§type Future = Pin<Box<dyn Future<Output = Response<UnsyncBoxBody<Bytes, Error>>> + Send>>
type Future = Pin<Box<dyn Future<Output = Response<UnsyncBoxBody<Bytes, Error>>> + Send>>
The type of future calling this handler returns.
Source§fn call(self, req: Request<Body>, _state: S) -> Self::Future
fn call(self, req: Request<Body>, _state: S) -> Self::Future
Call the handler with the given request.
Source§fn layer<L, NewReqBody>(self, layer: L) -> Layered<L, Self, T, S, B, NewReqBody>where
L: Layer<HandlerService<Self, T, S, B>> + Clone,
<L as Layer<HandlerService<Self, T, S, B>>>::Service: Service<Request<NewReqBody>>,
fn layer<L, NewReqBody>(self, layer: L) -> Layered<L, Self, T, S, B, NewReqBody>where
L: Layer<HandlerService<Self, T, S, B>> + Clone,
<L as Layer<HandlerService<Self, T, S, B>>>::Service: Service<Request<NewReqBody>>,
Apply a
tower::Layer
to the handler. Read moreSource§fn with_state(self, state: S) -> HandlerService<Self, T, S, B>
fn with_state(self, state: S) -> HandlerService<Self, T, S, B>
Convert the handler into a
Service
by providing the stateAuto Trait Implementations§
impl Freeze for FallbackHandler
impl !RefUnwindSafe for FallbackHandler
impl Send for FallbackHandler
impl Sync for FallbackHandler
impl Unpin for FallbackHandler
impl !UnwindSafe for FallbackHandler
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<H, T, B> HandlerWithoutStateExt<T, B> for H
impl<H, T, B> HandlerWithoutStateExt<T, B> for H
Source§fn into_service(self) -> HandlerService<H, T, (), B>
fn into_service(self) -> HandlerService<H, T, (), B>
Convert the handler into a
Service
and no state.Source§fn into_make_service(self) -> IntoMakeService<HandlerService<H, T, (), B>>
fn into_make_service(self) -> IntoMakeService<HandlerService<H, T, (), B>>
Convert the handler into a
MakeService
and no state. Read moreSource§fn into_make_service_with_connect_info<C>(
self,
) -> IntoMakeServiceWithConnectInfo<HandlerService<H, T, (), B>, C>
fn into_make_service_with_connect_info<C>( self, ) -> IntoMakeServiceWithConnectInfo<HandlerService<H, T, (), B>, C>
Convert the handler into a
MakeService
which stores information
about the incoming connection and has no state. Read more