pub struct TokenCookieConfig {
pub is_write_cookie: bool,
pub domain: Option<String>,
pub path: Option<String>,
pub http_only: bool,
pub secure: bool,
pub same_site: Option<SameSite>,
}Expand description
Cookie attributes used when a handler opts into writing the token cookie. Handler 选择写入 token Cookie 时使用的属性。
Fields§
When false, write_token_cookie is a no-op (default).
为 false 时 write_token_cookie 为空操作(默认)。
domain: Option<String>domain | domain
path: Option<String>path | path
http_only: boolhttp_only | http_only
secure: boolsecure | secure
same_site: Option<SameSite>same_site | same_site
Trait Implementations§
Source§impl Clone for TokenCookieConfig
impl Clone for TokenCookieConfig
Source§fn clone(&self) -> TokenCookieConfig
fn clone(&self) -> TokenCookieConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TokenCookieConfig
impl Debug for TokenCookieConfig
Source§impl Default for TokenCookieConfig
impl Default for TokenCookieConfig
Source§impl<'de> Deserialize<'de> for TokenCookieConfig
impl<'de> Deserialize<'de> for TokenCookieConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for TokenCookieConfig
impl RefUnwindSafe for TokenCookieConfig
impl Send for TokenCookieConfig
impl Sync for TokenCookieConfig
impl Unpin for TokenCookieConfig
impl UnsafeUnpin for TokenCookieConfig
impl UnwindSafe for TokenCookieConfig
Blanket Implementations§
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