#[non_exhaustive]pub enum Error {
Show 15 variants
InvalidOptions {
reason: String,
},
Metadata {
reason: String,
},
UnsupportedPixelData {
reason: String,
},
Unsupported {
reason: String,
},
SourceOpen {
path: PathBuf,
message: String,
},
Identity {
reason: String,
},
SlideRead {
message: String,
},
Encode {
message: String,
},
FrameEncode {
level: u32,
row: u64,
col: u64,
message: String,
},
Io {
path: PathBuf,
source: Error,
},
DicomWrite {
path: PathBuf,
message: String,
},
Json {
path: PathBuf,
source: Error,
},
JsonSerialize {
message: String,
},
ExportTransaction {
recovery_path: PathBuf,
reason: String,
},
Validation {
reason: String,
},
}Expand description
Error type returned by public wsi-dicom APIs.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
InvalidOptions
Export or validation options are internally inconsistent.
Metadata
Metadata is missing required fields or cannot be mapped safely.
UnsupportedPixelData
Source or prepared pixel data cannot be represented by the requested output.
Unsupported
The requested route, transfer syntax, or backend is unsupported.
SourceOpen
The source slide could not be opened.
Identity
DICOM export identity generation failed.
SlideRead
The source slide failed while reading pixels or metadata.
Encode
JPEG 2000 or HTJ2K encoding failed before a frame location was available.
FrameEncode
JPEG 2000 or HTJ2K encoding failed for one DICOM frame.
Fields
Io
Filesystem I/O failed at a known path.
DicomWrite
DICOM object construction or writing failed.
Fields
Json
JSON parsing failed at a known path.
JsonSerialize
JSON serialization failed.
ExportTransaction
A staged export could not be committed or rolled back completely.
Fields
Validation
External DICOM validation failed.
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)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for Error
impl !UnwindSafe for Error
impl Freeze for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin for Error
Blanket Implementations§
Source§impl<T> AsErrorSource for Twhere
T: Error + 'static,
impl<T> AsErrorSource for Twhere
T: Error + 'static,
Source§fn as_error_source(&self) -> &(dyn Error + 'static)
fn as_error_source(&self) -> &(dyn Error + 'static)
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more