pub enum DimacsError {
MissingHeader,
ClauseBeforeHeader {
line: usize,
},
InvalidHeader {
line: usize,
content: String,
},
InvalidLiteral {
line: usize,
token: String,
},
LiteralOutOfRange {
line: usize,
lit: isize,
max_vars: usize,
},
UnterminatedClause,
ClauseCountMismatch {
expected: usize,
parsed: usize,
},
Io(Error),
}Expand description
解析 DIMACS 文件时可能出现的错误。
Variants§
MissingHeader
ClauseBeforeHeader
InvalidHeader
InvalidLiteral
LiteralOutOfRange
UnterminatedClause
ClauseCountMismatch
Io(Error)
Trait Implementations§
Source§impl Debug for DimacsError
impl Debug for DimacsError
Source§impl Display for DimacsError
impl Display for DimacsError
Source§impl Error for DimacsError
impl Error for DimacsError
1.30.0 · 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 DimacsError
impl !RefUnwindSafe for DimacsError
impl Send for DimacsError
impl Sync for DimacsError
impl Unpin for DimacsError
impl UnsafeUnpin for DimacsError
impl !UnwindSafe for DimacsError
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