Enum jsonrpc_server_utils::cors::CorsHeader
[−]
[src]
pub enum CorsHeader<T = AccessControlAllowOrigin> { NotRequired, Invalid, Ok(T), }
CORS Header Result.
Variants
NotRequired
CORS header was not required. Origin is not present in the request.
Invalid
CORS header is not returned, Origin is not allowed to access the resource.
Ok(T)
CORS header to include in the response. Origin is allowed to access the resource.
Methods
impl<T> CorsHeader<T>
[src]
fn map<F, O>(self, f: F) -> CorsHeader<O> where
F: FnOnce(T) -> O,
F: FnOnce(T) -> O,
Maps Ok
variant of CorsHeader
.
Trait Implementations
impl<T: Debug> Debug for CorsHeader<T>
[src]
impl<T: Clone> Clone for CorsHeader<T>
[src]
fn clone(&self) -> CorsHeader<T>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<T: PartialEq> PartialEq for CorsHeader<T>
[src]
fn eq(&self, __arg_0: &CorsHeader<T>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &CorsHeader<T>) -> bool
This method tests for !=
.