pub struct MultiProgress { /* private fields */ }Expand description
Manages multiple concurrent progress bars and spinners with stable rendering.
§Example
use pulsebar::MultiProgress;
let multi = MultiProgress::new();
let bar1 = multi.add_bar(100).with_message("Compile");
let bar2 = multi.add_bar(200).with_message("Test");
bar1.advance(50);
bar2.advance(100);
bar1.finish_success("Compiled");
bar2.finish_success("Tests passed");Implementations§
Source§impl MultiProgress
impl MultiProgress
Sourcepub fn add_bar(&self, total: u64) -> ProgressBar
pub fn add_bar(&self, total: u64) -> ProgressBar
Add a progress bar with the given total and return a handle to it.
Sourcepub fn add_spinner(&self) -> Spinner
pub fn add_spinner(&self) -> Spinner
Add a spinner and return a handle to it.
Sourcepub fn join(self)
pub fn join(self)
Wait for all tasks to complete. This blocks until every added bar/spinner has been finished.
Sourcepub fn is_finished(&self) -> bool
pub fn is_finished(&self) -> bool
Check if all tasks are finished.
Trait Implementations§
Source§impl Default for MultiProgress
impl Default for MultiProgress
Auto Trait Implementations§
impl Freeze for MultiProgress
impl !RefUnwindSafe for MultiProgress
impl Send for MultiProgress
impl Sync for MultiProgress
impl Unpin for MultiProgress
impl UnsafeUnpin for MultiProgress
impl !UnwindSafe for MultiProgress
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