pub struct Cache<TMsg>(/* private fields */);
Expand description
Кеш сообщений
Implementations§
Source§impl<TMsg> Cache<TMsg>where
TMsg: MsgDataBound,
impl<TMsg> Cache<TMsg>where
TMsg: MsgDataBound,
Sourcepub fn blocking_read(
&self,
) -> RwLockReadGuard<'_, HashMap<String, Message<TMsg>>>
pub fn blocking_read( &self, ) -> RwLockReadGuard<'_, HashMap<String, Message<TMsg>>>
Блокировка кеша для чтения в синхронном коде
Sourcepub fn read(
&self,
) -> impl Future<Output = RwLockReadGuard<'_, HashMap<String, Message<TMsg>>>>
pub fn read( &self, ) -> impl Future<Output = RwLockReadGuard<'_, HashMap<String, Message<TMsg>>>>
Блокировка кеша для чтения
Trait Implementations§
Auto Trait Implementations§
impl<TMsg> Freeze for Cache<TMsg>
impl<TMsg> !RefUnwindSafe for Cache<TMsg>
impl<TMsg> Send for Cache<TMsg>
impl<TMsg> Sync for Cache<TMsg>
impl<TMsg> Unpin for Cache<TMsg>
impl<TMsg> !UnwindSafe for Cache<TMsg>
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