pub enum MiddlewareAction {
Proceed,
Respond {
response: Response,
validate_origin: bool,
validate_hosts: bool,
},
}Expand description
Request middleware action
Variants
Proceed
Proceed with standard JSON-RPC behaviour.
Respond
Fields
response: ResponseResponse to return
validate_origin: boolShould origin be validated before returning the response?
validate_hosts: boolShould hosts be validated before returning the response?
Terminate the request and return a response.
Trait Implementations
sourceimpl Debug for MiddlewareAction
impl Debug for MiddlewareAction
Auto Trait Implementations
impl RefUnwindSafe for MiddlewareAction
impl Send for MiddlewareAction
impl Sync for MiddlewareAction
impl Unpin for MiddlewareAction
impl UnwindSafe for MiddlewareAction
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more