pub struct ErrorResponse(pub ServerError);Expand description
ErrorResponse message - fatal error from server.
Tuple Fields§
§0: ServerErrorImplementations§
Source§impl ErrorResponse
impl ErrorResponse
Sourcepub fn parse(payload: &[u8]) -> Result<Self>
pub fn parse(payload: &[u8]) -> Result<Self>
Parse an ErrorResponse message from payload bytes.
Sourcepub fn into_error(self) -> Error
pub fn into_error(self) -> Error
Convert to an Error.
Sourcepub fn error(&self) -> &ServerError
pub fn error(&self) -> &ServerError
Get the underlying ServerError.
Trait Implementations§
Source§impl Clone for ErrorResponse
impl Clone for ErrorResponse
Source§fn clone(&self) -> ErrorResponse
fn clone(&self) -> ErrorResponse
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ErrorResponse
impl RefUnwindSafe for ErrorResponse
impl Send for ErrorResponse
impl Sync for ErrorResponse
impl Unpin for ErrorResponse
impl UnwindSafe for ErrorResponse
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