Struct finchers_session::cookie::CookieBackend [−][src]
pub struct CookieBackend { /* fields omitted */ }Methods
impl CookieBackend[src]
impl CookieBackendpub fn plain() -> CookieBackend[src]
pub fn plain() -> CookieBackendCreates a CookieSessionBackend which stores the Cookie values as a raw form.
pub fn signed(key: Key) -> CookieBackend[src]
pub fn signed(key: Key) -> CookieBackendCreates a CookieSessionBackend which signs the Cookie values with the specified secret key.
This method is only available if the feature flag secure is set.
pub fn private(key: Key) -> CookieBackend[src]
pub fn private(key: Key) -> CookieBackendCreates a CookieSessionBackend which encrypts the Cookie values with the specified secret key.
This method is only available if the feature flag secure is set.
pub fn path(
self,
value: impl Into<Cow<'static, str>>
) -> CookieBackend[src]
pub fn path(
self,
value: impl Into<Cow<'static, str>>
) -> CookieBackendSets the path of Cookie entry.
The default value is "/".
pub fn secure(self, value: bool) -> CookieBackend[src]
pub fn secure(self, value: bool) -> CookieBackendSets the value of secure in Cookie entry.
The default value is true.
pub fn http_only(self, value: bool) -> CookieBackend[src]
pub fn http_only(self, value: bool) -> CookieBackendSets the value of http_only in Cookie entry.
The default value is true.
pub fn domain(
self,
value: impl Into<Cow<'static, str>>
) -> CookieBackend[src]
pub fn domain(
self,
value: impl Into<Cow<'static, str>>
) -> CookieBackendSets the value of domain in Cookie entry.
The default value is None.
pub fn same_site(self, value: SameSite) -> CookieBackend[src]
pub fn same_site(self, value: SameSite) -> CookieBackendSets the value of same_site in Cookie entry.
The default value is None.
pub fn max_age(self, value: Duration) -> CookieBackend[src]
pub fn max_age(self, value: Duration) -> CookieBackendSets the value of max_age in Cookie entry.
The default value is None.
Trait Implementations
impl Debug for CookieBackend[src]
impl Debug for CookieBackendfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Clone for CookieBackend[src]
impl Clone for CookieBackendfn clone(&self) -> CookieBackend[src]
fn clone(&self) -> CookieBackendReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl<'a> Endpoint<'a> for CookieBackend[src]
impl<'a> Endpoint<'a> for CookieBackendtype Output = (Session<CookieSession>,)
The inner type associated with this endpoint.
type Future = FutureResult<Self::Output, Error>
The type of value which will be returned from apply.
fn apply(&self, cx: &mut ApplyContext) -> ApplyResult<Self::Future>[src]
fn apply(&self, cx: &mut ApplyContext) -> ApplyResult<Self::Future>Perform checking the incoming HTTP request and returns an instance of the associated Future if matched. Read more
fn with_output<T>(self) -> Self where
Self: Endpoint<'a, Output = T>,
T: Tuple, [src]
fn with_output<T>(self) -> Self where
Self: Endpoint<'a, Output = T>,
T: Tuple, Add an annotation that the associated type Output is fixed to T.
fn wrap<W>(self, wrapper: W) -> <W as Wrapper<'a, Self>>::Endpoint where
W: Wrapper<'a, Self>, [src]
fn wrap<W>(self, wrapper: W) -> <W as Wrapper<'a, Self>>::Endpoint where
W: Wrapper<'a, Self>, Converts self using the provided Wrapper.
Auto Trait Implementations
impl Send for CookieBackend
impl Send for CookieBackendimpl Sync for CookieBackend
impl Sync for CookieBackend