pub struct PeerAuthCache { /* private fields */ }๐Deprecated: Use the Session::peer instead
Expand description
In-memory chat cache, mapping peers to their respective access hashes.
Implementationsยง
Sourceยงimpl PeerAuthCache
impl PeerAuthCache
pub fn new(self_user: Option<(i64, bool)>) -> Self
pub fn self_id(&self) -> i64
pub fn is_self_bot(&self) -> bool
pub fn set_self_user(&mut self, user: PeerInfo)
pub fn get(&self, id: PeerId) -> Option<PeerRef>
pub fn extend(&mut self, users: &[User], chats: &[Chat]) -> bool
Auto Trait Implementationsยง
impl Freeze for PeerAuthCache
impl RefUnwindSafe for PeerAuthCache
impl Send for PeerAuthCache
impl Sync for PeerAuthCache
impl Unpin for PeerAuthCache
impl UnwindSafe for PeerAuthCache
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