pub struct SurfpoolWebsocketMiddleware {
pub surfpool_middleware: SurfpoolMiddleware,
pub session: Option<Arc<Session>>,
}Fields§
§surfpool_middleware: SurfpoolMiddleware§session: Option<Arc<Session>>Implementations§
Trait Implementations§
Source§impl Clone for SurfpoolWebsocketMiddleware
impl Clone for SurfpoolWebsocketMiddleware
Source§fn clone(&self) -> SurfpoolWebsocketMiddleware
fn clone(&self) -> SurfpoolWebsocketMiddleware
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Middleware<Option<SurfpoolWebsocketMeta>> for SurfpoolWebsocketMiddleware
impl Middleware<Option<SurfpoolWebsocketMeta>> for SurfpoolWebsocketMiddleware
Source§type Future = Pin<Box<dyn Future<Output = Option<Response>> + Send>>
type Future = Pin<Box<dyn Future<Output = Option<Response>> + Send>>
A returned request future.
Source§type CallFuture = Pin<Box<dyn Future<Output = Option<Output>> + Send>>
type CallFuture = Pin<Box<dyn Future<Output = Option<Output>> + Send>>
A returned call future.
Source§fn on_request<F, X>(
&self,
request: Request,
meta: Option<SurfpoolWebsocketMeta>,
next: F,
) -> Either<Self::Future, X>
fn on_request<F, X>( &self, request: Request, meta: Option<SurfpoolWebsocketMeta>, next: F, ) -> Either<Self::Future, X>
Method invoked on each request.
Allows you to either respond directly (without executing RPC call)
or do any additional work before and/or after processing the request.
Auto Trait Implementations§
impl Freeze for SurfpoolWebsocketMiddleware
impl !RefUnwindSafe for SurfpoolWebsocketMiddleware
impl Send for SurfpoolWebsocketMiddleware
impl Sync for SurfpoolWebsocketMiddleware
impl Unpin for SurfpoolWebsocketMiddleware
impl !UnwindSafe for SurfpoolWebsocketMiddleware
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more