Struct WeakProgressBar

pub struct WeakProgressBar { /* private fields */ }

A weak reference to a ProgressBar.

Useful for creating custom steady tick implementations

Implementations

impl WeakProgressBar

fn new() -> Self

Create a new WeakProgressBar that returns None when upgrade() is called.

fn upgrade(&self) -> Option<ProgressBar>

Attempts to upgrade the Weak pointer to a ProgressBar, delaying dropping of the inner value if successful. Returns None if the inner value has since been dropped.

Trait Implementations

impl Clone for WeakProgressBar

fn clone(&self) -> Self

impl Default for WeakProgressBar

fn default() -> Self

Auto Trait Implementations

impl Freeze for WeakProgressBar

impl RefUnwindSafe for WeakProgressBar

impl Send for WeakProgressBar

impl Sync for WeakProgressBar

impl Unpin for WeakProgressBar

impl UnsafeUnpin for WeakProgressBar

impl UnwindSafe for WeakProgressBar

Blanket Implementations

impl<T> Any for WeakProgressBar where T: 'static + ?Sized,

impl<T> Borrow<T> for WeakProgressBar where T: ?Sized,

impl<T> BorrowMut<T> for WeakProgressBar where T: ?Sized,

impl<T> CloneToUninit for WeakProgressBar where T: Clone,

impl<T> From<T> for WeakProgressBar

impl<T> ToOwned for WeakProgressBar where T: Clone,

impl<T, U> Into<U> for WeakProgressBar where U: From<T>,

impl<T, U> TryFrom<U> for WeakProgressBar where U: Into<T>,

impl<T, U> TryInto<U> for WeakProgressBar where U: TryFrom<T>,