pub struct BatchQueue { /* private fields */ }Expand description
Implementations§
Source§impl BatchQueue
impl BatchQueue
Sourcepub fn new(max_size: usize) -> Self
pub fn new(max_size: usize) -> Self
Create a new BatchQueue with the given maximum buffer size.
Sourcepub fn push(&self, score: ScoreBody) -> bool
pub fn push(&self, score: ScoreBody) -> bool
Add a score to the queue.
Returns true if the queue has reached max_size (flush needed).
Auto Trait Implementations§
impl Freeze for BatchQueue
impl RefUnwindSafe for BatchQueue
impl Send for BatchQueue
impl Sync for BatchQueue
impl Unpin for BatchQueue
impl UnsafeUnpin for BatchQueue
impl UnwindSafe for BatchQueue
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