[−][src]Struct eve_rs::DefaultContext
Implementations
impl DefaultContext
[src]
pub fn get_body_object(&self) -> Option<&Value>
[src]
pub fn set_body_object(&mut self, body: Value)
[src]
pub fn new(request: Request) -> Self
[src]
Trait Implementations
impl Context for DefaultContext
[src]
pub fn get_request(&self) -> &Request
[src]
pub fn get_request_mut(&mut self) -> &mut Request
[src]
pub fn get_response(&self) -> &Response
[src]
pub fn take_response(self) -> Response
[src]
pub fn get_response_mut(&mut self) -> &mut Response
[src]
pub fn get_body(&self) -> Result<String, Utf8Error>
[src]
pub fn json(&mut self, body: Value) -> &mut Self
[src]
pub fn body(&mut self, string: &str) -> &mut Self
[src]
pub fn body_bytes(&mut self, bytes: &[u8]) -> &mut Self
[src]
pub fn get_method(&self) -> &HttpMethod
[src]
pub fn get_status(&self) -> u16
[src]
pub fn get_status_message(&self) -> &str
[src]
pub fn status(&mut self, code: u16) -> &mut Self
[src]
pub fn content_type(&mut self, content_type: &str) -> &mut Self
[src]
pub fn content_length(&mut self, length: usize) -> &mut Self
[src]
pub fn redirect(&mut self, destination: &str) -> &mut Self
[src]
pub fn attachment(&mut self, file_name: Option<&str>) -> &mut Self
[src]
pub fn get_path(&self) -> String
[src]
pub fn get_full_url(&self) -> String
[src]
pub fn get_origin(&self) -> Option<String>
[src]
pub fn get_query_string(&self) -> String
[src]
pub fn get_host(&self) -> String
[src]
pub fn get_host_and_port(&self) -> String
[src]
pub fn get_content_type(&self) -> String
[src]
pub fn get_charset(&self) -> Option<String>
[src]
pub fn get_protocol(&self) -> String
[src]
pub fn is_secure(&self) -> bool
[src]
pub fn get_ip(&self) -> IpAddr
[src]
pub fn is(&self, mimes: &[&str]) -> bool
[src]
pub fn get_header(&self, key: &str) -> Option<String>
[src]
pub fn header(&mut self, key: &str, value: &str) -> &mut Self
[src]
pub fn append_header(&mut self, key: &str, value: &str) -> &mut Self
[src]
pub fn remove_header(&mut self, key: &str) -> &mut Self
[src]
pub fn get_cookie(&self, name: &str) -> Option<&Cookie>
[src]
pub fn get_cookies(&self) -> &Vec<Cookie>
[src]
pub fn cookie(&mut self, cookie: Cookie) -> &mut Self
[src]
pub fn last_modified(&mut self, last_modified: &str) -> &mut Self
[src]
pub fn etag(&mut self, etag: &str) -> &mut Self
[src]
impl Debug for DefaultContext
[src]
impl<TData> Middleware<DefaultContext> for DefaultMiddleware<TData> where
TData: Default + Clone + Send + Sync,
[src]
TData: Default + Clone + Send + Sync,
pub fn run_middleware<'life0, 'async_trait>(
&'life0 self,
context: DefaultContext,
next: NextHandler<DefaultContext>
) -> Pin<Box<dyn Future<Output = Result<DefaultContext, Error<DefaultContext>>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
context: DefaultContext,
next: NextHandler<DefaultContext>
) -> Pin<Box<dyn Future<Output = Result<DefaultContext, Error<DefaultContext>>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Auto Trait Implementations
impl RefUnwindSafe for DefaultContext
impl Send for DefaultContext
impl Sync for DefaultContext
impl Unpin for DefaultContext
impl UnwindSafe for DefaultContext
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,