pub enum WsPrismError {
BadRequest(String),
AuthFailed,
RateLimited,
PayloadTooLarge,
NotAllowed(String),
ResourceExhausted(String),
UnsupportedVersion,
Internal(String),
}Expand description
Unified error type used by core and gateway layers.
Variants§
BadRequest(String)
AuthFailed
RateLimited
PayloadTooLarge
NotAllowed(String)
ResourceExhausted(String)
UnsupportedVersion
Internal(String)
Implementations§
Source§impl WsPrismError
impl WsPrismError
Sourcepub fn client_code(&self) -> ClientCode
pub fn client_code(&self) -> ClientCode
Map internal error to a stable client-facing code.
Trait Implementations§
Source§impl Debug for WsPrismError
impl Debug for WsPrismError
Source§impl Display for WsPrismError
impl Display for WsPrismError
Source§impl Error for WsPrismError
impl Error for WsPrismError
1.30.0 · 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()
Auto Trait Implementations§
impl Freeze for WsPrismError
impl RefUnwindSafe for WsPrismError
impl Send for WsPrismError
impl Sync for WsPrismError
impl Unpin for WsPrismError
impl UnwindSafe for WsPrismError
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