#[non_exhaustive]pub enum CpdbError {
}Expand description
Errors that originate from the cpdb-rs bindings.
This type is #[non_exhaustive] — match arms must include a wildcard
so adding variants in future minor releases is not a breaking change.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NullPointer
A C function returned NULL where a valid pointer was required.
InvalidPrinter
A printer object pointer is invalid or has been released.
NotFound(String)
A lookup (printer, option, media, translation, …) returned no result.
PrinterError(String)
A printer-side operation failed (set default, accept jobs, …).
JobFailed(String)
A print job submission failed.
BackendError(String)
A backend-side operation failed.
FrontendError(String)
A frontend-side operation failed (D-Bus, lifecycle, …).
OptionError(String)
A printer option could not be parsed or applied.
Utf8Error(Utf8Error)
A C string returned by cpdb-libs contained invalid UTF-8.
NulError(NulError)
A Rust string contained an interior NUL byte.
IoError(Error)
An I/O error bubbled up from std::io.
InvalidStatus(i32)
An unexpected status code was returned.
Unsupported
The requested operation is not supported.
Trait Implementations§
Source§impl Error for CpdbError
impl Error for CpdbError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()