#[non_exhaustive]pub enum BadOfdException {
CorruptedStructure {
message: String,
},
ParseFailed {
message: String,
},
FileNotFound {
path: String,
},
Other(OfdError),
}Expand description
错误 OFD 文件结构和文档格式异常。
当 OFD 文档结构损坏、格式不符合 GB/T 33190 规范, 或解析过程中遇到不可恢复的错误时抛出。
对应 Java: org.ofdrw.reader.BadOFDException
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Implementations§
Trait Implementations§
Source§impl Debug for BadOfdException
impl Debug for BadOfdException
Source§impl Display for BadOfdException
impl Display for BadOfdException
Source§impl Error for BadOfdException
impl Error for BadOfdException
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()
Source§impl From<BadOfdException> for OfdError
impl From<BadOfdException> for OfdError
Source§fn from(e: BadOfdException) -> Self
fn from(e: BadOfdException) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for BadOfdException
impl !UnwindSafe for BadOfdException
impl Freeze for BadOfdException
impl Send for BadOfdException
impl Sync for BadOfdException
impl Unpin for BadOfdException
impl UnsafeUnpin for BadOfdException
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