[−][src]Enum kyansel::CancellableResult
Result returned by Cancellable
Variants
If the inner future finished
If the inner future was cancelled
Methods
impl<T, S> CancellableResult<T, S>
[src]
pub fn is_cancelled(&self) -> bool
[src]
Check if the future was cancelled
pub fn finished(self) -> Option<T>
[src]
Retrieve the result of the future if it was not cancelled
pub fn cancelled(self) -> Option<S>
[src]
Retrieve the result of the canceller future if the future was cancelled
Trait Implementations
impl<T: Clone, S: Clone> Clone for CancellableResult<T, S>
[src]
fn clone(&self) -> CancellableResult<T, S>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<T: Copy, S: Copy> Copy for CancellableResult<T, S>
[src]
impl<T: Eq, S: Eq> Eq for CancellableResult<T, S>
[src]
impl<T: PartialEq, S: PartialEq> PartialEq<CancellableResult<T, S>> for CancellableResult<T, S>
[src]
fn eq(&self, other: &CancellableResult<T, S>) -> bool
[src]
fn ne(&self, other: &CancellableResult<T, S>) -> bool
[src]
impl<T: Debug, S: Debug> Debug for CancellableResult<T, S>
[src]
impl<T, S> StructuralPartialEq for CancellableResult<T, S>
[src]
impl<T, S> StructuralEq for CancellableResult<T, S>
[src]
Auto Trait Implementations
impl<T, S> Send for CancellableResult<T, S> where
S: Send,
T: Send,
S: Send,
T: Send,
impl<T, S> Sync for CancellableResult<T, S> where
S: Sync,
T: Sync,
S: Sync,
T: Sync,
impl<T, S> Unpin for CancellableResult<T, S> where
S: Unpin,
T: Unpin,
S: Unpin,
T: Unpin,
impl<T, S> UnwindSafe for CancellableResult<T, S> where
S: UnwindSafe,
T: UnwindSafe,
S: UnwindSafe,
T: UnwindSafe,
impl<T, S> RefUnwindSafe for CancellableResult<T, S> where
S: RefUnwindSafe,
T: RefUnwindSafe,
S: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,