Skip to main content

Rejected

Type Alias Rejected 

Source
pub type Rejected<T> = Result<T, StatusCode>;
Expand description

The result of anything that judges a peer’s message: the failure is the status code the peer must be told.

Not crate::Result, and deliberately: §11.22.3.2’s codes are the entire content of a BDX failure, and folding them into a general error would throw away the only thing the caller needs in order to answer.

Aliased Type§

pub enum Rejected<T> {
    Ok(T),
    Err(StatusCode),
}

Variants§

§1.0.0

Ok(T)

Contains the success value

§1.0.0

Err(StatusCode)

Contains the error value