pub enum VmbError {
Sdk {
code: i32,
message: String,
},
NotStarted,
AlreadyStarted,
Io {
path: PathBuf,
source: Error,
},
InvalidString {
context: &'static str,
},
CaptureAlreadyRunning,
FrameTooSmall {
expected: usize,
actual: usize,
},
}Expand description
Errors returned by the safe vmb wrapper.
Variants§
Sdk
A non-success return code from a VmbC call.
Fields
NotStarted
The Vimba runtime has not been started, or was already shut down.
AlreadyStarted
Attempted to start the Vimba runtime while a previous VmbSystem
instance is still alive. The runtime is process-global and the
wrapper enforces a singleton invariant.
Io
I/O failure while reading a settings XML file (or a related path).
InvalidString
A string supplied by the SDK or by the caller was not valid UTF-8 or contained an interior nul byte.
CaptureAlreadyRunning
Camera::start_capture was called while a previous capture is still
running on the same camera.
FrameTooSmall
A received frame was smaller than expected for its declared format.
Trait Implementations§
Source§impl Error for VmbError
impl Error for VmbError
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 VmbError
impl !RefUnwindSafe for VmbError
impl Send for VmbError
impl Sync for VmbError
impl Unpin for VmbError
impl UnsafeUnpin for VmbError
impl !UnwindSafe for VmbError
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