pub struct CursorTable { /* private fields */ }Expand description
The member cursor and one cursor per channel (§10).
SPEC: §10 does not say where a channel’s cursor starts when the client has none (a new
channel, or one it never listed). It starts at 0, so a first event above 1 is a gap and
sync.resume reports the channel’s floor (§10.6), which then raises the cursor.
Implementations§
Source§impl CursorTable
impl CursorTable
Sourcepub fn resume_bodies(&self) -> Vec<Resume>
pub fn resume_bodies(&self) -> Vec<Resume>
sync.resume bodies for every tracked stream, at most 100 channels each (§10.3).
Source§impl CursorTable
impl CursorTable
Sourcepub fn set_member(&mut self, seq: u64)
pub fn set_member(&mut self, seq: u64)
Sets the member cursor exactly (after a snapshot, §10.1), dropping held events.
Sourcepub fn set_channel(&mut self, id: ChannelId, seq: u64)
pub fn set_channel(&mut self, id: ChannelId, seq: u64)
Sets a channel cursor exactly (after paging history), dropping held events.
Sourcepub fn remove_channel(&mut self, id: &ChannelId)
pub fn remove_channel(&mut self, id: &ChannelId)
Stops tracking a channel (lost access, sync.resume.hidden).
Trait Implementations§
Source§impl Clone for CursorTable
impl Clone for CursorTable
Source§fn clone(&self) -> CursorTable
fn clone(&self) -> CursorTable
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CursorTable
impl Debug for CursorTable
Source§impl Default for CursorTable
impl Default for CursorTable
Source§fn default() -> CursorTable
fn default() -> CursorTable
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CursorTable
impl RefUnwindSafe for CursorTable
impl Send for CursorTable
impl Sync for CursorTable
impl Unpin for CursorTable
impl UnsafeUnpin for CursorTable
impl UnwindSafe for CursorTable
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