pub enum SperrCodecError {
UnsupportedDtype(AnyArrayDType),
HeaderEncodeFailed {
source: SperrHeaderError,
},
SperrEncodeFailed {
source: SperrCodingError,
},
SliceEncodeFailed {
source: SperrSliceError,
},
EncodedDataNotBytes {
dtype: AnyArrayDType,
},
EncodedDataNotOneDimensional {
shape: Vec<usize>,
},
HeaderDecodeFailed {
source: SperrHeaderError,
},
SliceDecodeFailed {
source: SperrSliceError,
},
DecodeTooManySlices,
SperrDecodeFailed {
source: SperrCodingError,
},
DecodeInvalidShape {
source: ShapeError,
},
MismatchedDecodeIntoArray {
source: AnyArrayAssignError,
},
}Expand description
Errors that may occur when applying the SperrCodec.
Variants§
UnsupportedDtype(AnyArrayDType)
SperrCodec does not support the dtype
HeaderEncodeFailed
SperrCodec failed to encode the header
Fields
source: SperrHeaderErrorOpaque source error
SperrEncodeFailed
SperrCodec failed to encode the data
Fields
source: SperrCodingErrorOpaque source error
SliceEncodeFailed
SperrCodec failed to encode a slice
Fields
source: SperrSliceErrorOpaque source error
EncodedDataNotBytes
SperrCodec can only decode one-dimensional byte arrays but received
an array of a different dtype
Fields
dtype: AnyArrayDTypeThe unexpected dtype of the encoded array
EncodedDataNotOneDimensional
SperrCodec can only decode one-dimensional byte arrays but received
an array of a different shape
HeaderDecodeFailed
SperrCodec failed to decode the header
Fields
source: SperrHeaderErrorOpaque source error
SliceDecodeFailed
SperrCodec failed to decode a slice
Fields
source: SperrSliceErrorOpaque source error
DecodeTooManySlices
SperrCodec failed to decode from an excessive number of slices
SperrDecodeFailed
SperrCodec failed to decode the data
Fields
source: SperrCodingErrorOpaque source error
DecodeInvalidShape
SperrCodec decoded into an invalid shape not matching the data size
Fields
source: ShapeErrorThe source of the error
MismatchedDecodeIntoArray
SperrCodec cannot decode into the provided array
Fields
source: AnyArrayAssignErrorThe source of the error
Trait Implementations§
Source§impl Debug for SperrCodecError
impl Debug for SperrCodecError
Source§impl Display for SperrCodecError
impl Display for SperrCodecError
Source§impl Error for SperrCodecError
impl Error for SperrCodecError
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()