pub enum Error {
    Io(Error),
    Serialize(Error),
    Connection(String),
    Protocol(ProtocolError),
    Timeout(String),
    TimedOut(Elapsed),
    Auth(String),
    MessageHandling(String),
    Config(String),
    Http(Error),
    Other(String),
}Expand description
NSQ客户端库错误类型
Variants§
Io(Error)
IO错误
Serialize(Error)
序列化错误
Connection(String)
连接错误
Protocol(ProtocolError)
协议错误
Timeout(String)
超时错误
TimedOut(Elapsed)
tokio 超时错误
Auth(String)
认证错误
MessageHandling(String)
消息处理错误
Config(String)
配置错误
Http(Error)
HTTP错误
Other(String)
其他错误
Trait Implementations§
Source§impl Error for Error
 
impl Error for Error
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<ProtocolError> for Error
 
impl From<ProtocolError> for Error
Source§fn from(source: ProtocolError) -> Self
 
fn from(source: ProtocolError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
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