pub enum TryAcquireError<P, C: IsCloseable> {
NoPermits(P),
Closed(C::AcquireError<P>),
Poisoned(P),
}Variants§
NoPermits(P)
The semaphore had no permits to give out right now.
Closed(C::AcquireError<P>)
The semaphore is closed.
Poisoned(P)
The semaphore is poisoned: a previous SemaphoreState::acquire
call panicked. The params are handed back unused.
Trait Implementations§
Source§impl<P: Debug, C: Debug + IsCloseable> Debug for TryAcquireError<P, C>where
C::AcquireError<P>: Debug,
impl<P: Debug, C: Debug + IsCloseable> Debug for TryAcquireError<P, C>where
C::AcquireError<P>: Debug,
Source§impl<P, C: IsCloseable> Display for TryAcquireError<P, C>
impl<P, C: IsCloseable> Display for TryAcquireError<P, C>
impl<P: Eq, C: Eq + IsCloseable> Eq for TryAcquireError<P, C>where
C::AcquireError<P>: Eq,
Source§impl<P: PartialEq, C: PartialEq + IsCloseable> PartialEq for TryAcquireError<P, C>where
C::AcquireError<P>: PartialEq,
impl<P: PartialEq, C: PartialEq + IsCloseable> PartialEq for TryAcquireError<P, C>where
C::AcquireError<P>: PartialEq,
Source§fn eq(&self, other: &TryAcquireError<P, C>) -> bool
fn eq(&self, other: &TryAcquireError<P, C>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<P: PartialEq, C: PartialEq + IsCloseable> StructuralPartialEq for TryAcquireError<P, C>where
C::AcquireError<P>: PartialEq,
Auto Trait Implementations§
impl<P, C> Freeze for TryAcquireError<P, C>
impl<P, C> RefUnwindSafe for TryAcquireError<P, C>
impl<P, C> Send for TryAcquireError<P, C>
impl<P, C> Sync for TryAcquireError<P, C>
impl<P, C> Unpin for TryAcquireError<P, C>
impl<P, C> UnsafeUnpin for TryAcquireError<P, C>
impl<P, C> UnwindSafe for TryAcquireError<P, C>
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