Skip to main content

Completion

Enum Completion 

Source
pub enum Completion<O: Operation, C, CE> {
    Success {
        output: O::Output,
        chain: C,
    },
    DeviceError {
        status: StatusCode,
        disposition: FailureDisposition,
        operation: O,
        chain: C,
    },
    InvalidResponse {
        error: ResponseError<CE>,
        operation: O,
        chain: C,
    },
}
Expand description

Terminal result for one matched request completion.

Variants§

§

Success

Protocol success with the reclaimed caller chain.

Fields

§output: O::Output

Typed response value. Bulk read bytes remain in chain.

§chain: C

Reclaimed caller-owned chain.

§

DeviceError

Well-formed protocol error; operation metadata is returned for retry decisions.

Fields

§status: StatusCode

Raw status, preserving unknown provider values.

§disposition: FailureDisposition

Whether typed operation ownership is retryable, invalid, or uncertain.

§operation: O

Original typed operation.

§chain: C

Reclaimed caller-owned chain.

§

InvalidResponse

Malformed or inaccessible response; reset is required.

Fields

§error: ResponseError<CE>

Validation failure.

§operation: O

Original typed operation.

§chain: C

Reclaimed caller-owned chain.

Trait Implementations§

Source§

impl<O: Debug + Operation, C: Debug, CE: Debug> Debug for Completion<O, C, CE>
where O::Output: Debug,

Source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<O, C, CE> Freeze for Completion<O, C, CE>
where <O as Operation>::Output: Freeze, C: Freeze, O: Freeze, CE: Freeze,

§

impl<O, C, CE> RefUnwindSafe for Completion<O, C, CE>

§

impl<O, C, CE> Send for Completion<O, C, CE>
where <O as Operation>::Output: Send, C: Send, O: Send, CE: Send,

§

impl<O, C, CE> Sync for Completion<O, C, CE>
where <O as Operation>::Output: Sync, C: Sync, O: Sync, CE: Sync,

§

impl<O, C, CE> Unpin for Completion<O, C, CE>
where <O as Operation>::Output: Unpin, C: Unpin, O: Unpin, CE: Unpin,

§

impl<O, C, CE> UnsafeUnpin for Completion<O, C, CE>

§

impl<O, C, CE> UnwindSafe for Completion<O, C, CE>

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
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

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.

§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

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

Source§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.