Skip to main content

Acquisition

Enum Acquisition 

Source
pub enum Acquisition<P, B> {
    Existing(P),
    Build(B),
}
Expand description

An admission opportunity: use an existing resource or construct a new one. A build permit reserves capacity before any asynchronous construction.

Variants§

§

Existing(P)

§

Build(B)

Trait Implementations§

Source§

impl<P: Debug, B: Debug> Debug for Acquisition<P, B>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<P, B> Freeze for Acquisition<P, B>
where P: Freeze, B: Freeze,

§

impl<P, B> RefUnwindSafe for Acquisition<P, B>

§

impl<P, B> Send for Acquisition<P, B>
where P: Send, B: Send,

§

impl<P, B> Sync for Acquisition<P, B>
where P: Sync, B: Sync,

§

impl<P, B> Unpin for Acquisition<P, B>
where P: Unpin, B: Unpin,

§

impl<P, B> UnsafeUnpin for Acquisition<P, B>
where P: UnsafeUnpin, B: UnsafeUnpin,

§

impl<P, B> UnwindSafe for Acquisition<P, B>
where P: UnwindSafe, B: UnwindSafe,

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

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

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

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

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

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

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.