pub enum Error {
AddressParse(AddrParseError),
IO(Error),
CommandTooLong,
UTFEncoding(FromUtf8Error),
UnexpectedPacket,
PasswordIncorrect,
BusyReconnecting(String),
}
Expand description
A common error enum that is returned by all public functions describing different forms of failures that can occur within this library.
Variants§
AddressParse(AddrParseError)
There is an error in the passed address field
IO(Error)
There was a network issue during connection or exec
CommandTooLong
The command provided is longer than 1014 characters.
UTFEncoding(FromUtf8Error)
The server did not respond with proper UTF-8
UnexpectedPacket
The server sent a packet with a type we were not expecting.
PasswordIncorrect
The pass field is incorrect
BusyReconnecting(String)
Returned by ReConnection::exec
when ReConnection
is busy reconnecting.
Trait Implementations§
Source§impl Error for RconError
impl Error for RconError
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<AddrParseError> for RconError
impl From<AddrParseError> for RconError
Source§fn from(e: AddrParseError) -> Self
fn from(e: AddrParseError) -> Self
Converts to this type from the input type.
Source§impl From<FromUtf8Error> for RconError
impl From<FromUtf8Error> for RconError
Source§fn from(e: FromUtf8Error) -> Self
fn from(e: FromUtf8Error) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for RconError
impl !RefUnwindSafe for RconError
impl Send for RconError
impl Sync for RconError
impl Unpin for RconError
impl !UnwindSafe for RconError
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