pub enum CanError {
InitializeError(String),
NotImplementedError,
NotSupportedError,
TimeoutError(String),
OperationError(String),
OtherError(String),
}Variants§
InitializeError(String)
Error when operation like library loading, device or channel opening and so on.
NotImplementedError
Error when function is not implemented.
NotSupportedError
Error when function is not supported.
TimeoutError(String)
Error when operation timeout.
OperationError(String)
Error when operation like transmit, receive and so on.
OtherError(String)
Error when others.
Implementations§
Source§impl Error
impl Error
pub fn interface_not_matched<T: Display>(i: T) -> Self
pub fn device_open_error<T: Display>(msg: T) -> Self
pub fn device_not_opened() -> Self
pub fn channel_not_opened<T: Display>(channel: T) -> Self
pub fn channel_timeout<T: Display>(channel: T) -> Self
pub fn operation_error<T: Into<String>>(msg: T) -> Self
pub fn other_error<T: Into<String>>(msg: T) -> Self
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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 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