pub struct NativeChannelPresence { /* private fields */ }Expand description
Current Presence state and changes for a native channel.
Implementations§
Source§impl NativeChannelPresence
impl NativeChannelPresence
Sourcepub fn state(&self) -> &PresenceState
pub fn state(&self) -> &PresenceState
Returns the current synchronized Presence state.
Sourcepub fn requires_resync(&self) -> bool
pub fn requires_resync(&self) -> bool
Returns whether event lag invalidated local state.
Sourcepub async fn resync(&mut self) -> Result<(), NativeRuntimeError>
pub async fn resync(&mut self) -> Result<(), NativeRuntimeError>
Clears local state, leaves, and rejoins to request a fresh state.
Sourcepub async fn next(&mut self) -> Result<PresenceEvent, NativePresenceError>
pub async fn next(&mut self) -> Result<PresenceEvent, NativePresenceError>
Waits for the next Presence change or channel lifecycle event.
Auto Trait Implementations§
impl Freeze for NativeChannelPresence
impl RefUnwindSafe for NativeChannelPresence
impl Send for NativeChannelPresence
impl Sync for NativeChannelPresence
impl Unpin for NativeChannelPresence
impl UnsafeUnpin for NativeChannelPresence
impl UnwindSafe for NativeChannelPresence
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