#[non_exhaustive]pub enum InferenceError {
Transport(AppError),
Decode(String),
Server {
status: u16,
body: String,
},
Authorization(String),
InvalidInput(String),
Policy(String),
NotImplemented(&'static str),
Cancelled,
Timeout,
}Expand description
Typed inference failure.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Transport(AppError)
Transport error from an injected client or adapter boundary.
Decode(String)
Response decode or protocol mapping failure.
Server
Serving runtime returned an unsuccessful response.
Authorization(String)
Request was denied by an injected authorization decider.
InvalidInput(String)
Request or adapter selection input was invalid.
Policy(String)
Injected resilience policy failed the operation.
NotImplemented(&'static str)
Requested adapter capability is not implemented yet.
Cancelled
Operation was cancelled.
Timeout
Operation timed out.
Trait Implementations§
Source§impl Debug for InferenceError
impl Debug for InferenceError
Source§impl Display for InferenceError
impl Display for InferenceError
Source§impl Error for InferenceError
impl Error for InferenceError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<AppError> for InferenceError
impl From<AppError> for InferenceError
Source§impl From<InferenceError> for AppError
impl From<InferenceError> for AppError
Source§fn from(value: InferenceError) -> Self
fn from(value: InferenceError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for InferenceError
impl !UnwindSafe for InferenceError
impl Freeze for InferenceError
impl Send for InferenceError
impl Sync for InferenceError
impl Unpin for InferenceError
impl UnsafeUnpin for InferenceError
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