#[non_exhaustive]pub enum TabularError {
RaggedRow {
entity: &'static str,
row: usize,
expected: usize,
found: usize,
},
TooManyHeadings {
entity: &'static str,
found: usize,
},
EmptyList {
entity: &'static str,
attribute: &'static str,
},
BlankRequired {
entity: &'static str,
attribute: &'static str,
},
NotFinite {
entity: &'static str,
attribute: &'static str,
},
}Expand description
Why a tabular record was refused.
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.
RaggedRow
A row carries a different cell count than the first row (WR1).
Ragged tables parse and render; the damage appears only when a reader indexes a column the short row does not have.
Fields
TooManyHeadings
More than one row is marked as a heading (WR2).
Fields
EmptyList
A required list was empty.
The schema spells these LIST [1:?], so an empty list is not a
sparse record but a malformed one.
Fields
BlankRequired
A required label was absent or whitespace-only.
A blank string satisfies EXISTS while naming nothing, so it is refused rather than written.
Fields
NotFinite
A numeric attribute was not finite.
Trait Implementations§
Source§impl Clone for TabularError
impl Clone for TabularError
Source§impl Debug for TabularError
impl Debug for TabularError
Source§impl Display for TabularError
impl Display for TabularError
impl Eq for TabularError
Source§impl Error for TabularError
impl Error for TabularError
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()
Source§impl PartialEq for TabularError
impl PartialEq for TabularError
impl StructuralPartialEq for TabularError
Auto Trait Implementations§
impl Freeze for TabularError
impl RefUnwindSafe for TabularError
impl Send for TabularError
impl Sync for TabularError
impl Unpin for TabularError
impl UnsafeUnpin for TabularError
impl UnwindSafe for TabularError
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