pub struct WidgetSessions {
sessions: HashMap<String, WidgetSession>,
}Expand description
Active widget frame sessions, keyed by an opaque session ID.
Fields§
§sessions: HashMap<String, WidgetSession>Implementations§
Source§impl WidgetSessions
impl WidgetSessions
Sourcepub fn insert(&mut self, session_id: String, session: WidgetSession)
pub fn insert(&mut self, session_id: String, session: WidgetSession)
Registers a session.
Sourcepub fn remove(&mut self, session_id: &str) -> Option<WidgetSession>
pub fn remove(&mut self, session_id: &str) -> Option<WidgetSession>
Ends a session.
Authorizes a message for a session, rejecting it when the claimed widget ID doesn’t match the session’s widget.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for WidgetSessions
impl RefUnwindSafe for WidgetSessions
impl Send for WidgetSessions
impl Sync for WidgetSessions
impl Unpin for WidgetSessions
impl UnsafeUnpin for WidgetSessions
impl UnwindSafe for WidgetSessions
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