跳到主要内容

NoServerSessionStorage

结构体 NoServerSessionStorage 

Source
pub struct NoServerSessionStorage {}
展开描述

从不存储会话的对象。

Trait 实现§

Source§

impl Debug for NoServerSessionStorage

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

使用给定的格式化器格式化此值。 更多信息
Source§

impl StoresServerSessions for NoServerSessionStorage

Source§

fn put(&self, _id: Vec<u8>, _sec: Vec<u8>) -> bool

Store session secrets encoded in value against key, overwrites any existing value against key. Returns true 则返回 true。
Source§

fn get(&self, _id: &[u8]) -> Option<Vec<u8>>

Find 一个 value with the given key. Return it, 或 None if it doesn’t exist.
Source§

fn take(&self, _id: &[u8]) -> Option<Vec<u8>>

Find 一个 value with the given key. Return it 并 delete it; 或 None if it doesn’t exist.
Source§

fn can_cache(&self) -> bool

存储器是否可以缓存另一个会话。这用来向客户端指示 whether their session can be resumed; the implementation is not required 到 remember 会话 even if it returns true here.

自动 Trait 实现§

Blanket 实现§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. 更多信息
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows 从 an owned value. 更多信息
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows 从 an owned value. 更多信息
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

原样返回传入的参数。

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::从(self)

That is, this conversion is whatever the implementation of From<T> 用于 U 的实现方式。

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

转换出错时返回的类型。
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

执行转换。
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

转换出错时返回的类型。
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

执行转换。