pub struct Spinner { /* private fields */ }Implementations§
Source§impl Spinner
impl Spinner
pub fn new() -> Self
pub fn with_prefix(prefix: String) -> Self
pub fn with_style(style: ProgressStyle) -> Self
pub fn with_elapsed(elapsed: Duration) -> Self
pub fn with_finish(finish: ProgressFinish) -> Self
pub fn with_options(options: SpinnerOptions) -> Self
pub fn with( elapsed: Option<Duration>, finish: Option<ProgressFinish>, options: SpinnerOptions, ) -> Self
pub fn spin(&self) -> Result<()>
pub fn tick(&self)
pub fn run<T: Send + 'static, F: FnOnce() -> T + Send + 'static>( &self, process: F, ) -> Result<T>
pub fn suspend<F: FnOnce() -> R, R>(&self, f: F) -> R
pub fn set_steady_tick(&self, interval: u64)
pub fn message(&self) -> String
pub fn set_message(&self, message: impl Into<Cow<'static, str>>)
pub fn clear_message(&self)
pub fn prefix(&self) -> String
pub fn set_prefix(&self, prefix: impl Into<Cow<'static, str>>)
pub fn clear_prefix(&self)
pub fn duration(&self) -> Duration
pub fn elapsed(&self) -> Duration
pub fn eta(&self) -> Duration
pub fn is_finished(&self) -> bool
pub fn finish(&self) -> Result<()>
pub fn finish_with_message( &self, message: impl Into<Cow<'static, str>>, ) -> Result<()>
pub fn finish_using_style(&self) -> Result<()>
pub fn finish_and_clear(&self) -> Result<()>
pub fn abandon(&self) -> Result<()>
pub fn abandon_with_message(&self, message: String) -> Result<()>
pub fn reset_elapsed(&self)
pub fn reset_eta(&self)
pub fn reset(&self) -> Result<()>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Spinner
impl RefUnwindSafe for Spinner
impl Send for Spinner
impl Sync for Spinner
impl Unpin for Spinner
impl UnsafeUnpin for Spinner
impl UnwindSafe for Spinner
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