#[non_exhaustive]pub enum WorkbookError {
EmptyLiteral,
Validation(String),
SheetManagement(String),
Mutation(String),
}Expand description
Errors from workbook value-type constructors and from
Workbook::from_json /
Workbook::to_json.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
EmptyLiteral
A formula-less cell whose value is empty is invalid: it would be
byte-distinguishable from the absent cell it denotes, breaking
canonical uniqueness (schema spec §4). Clear a cell by removing its
entry from the sheet’s cell map instead.
Validation(String)
A document-level rule was violated while parsing or serializing — a rule serde cannot express (schema spec §1, §2, §3, §5, §7, §8) or a resource-limit breach (scope ADR Decision 5). Carries a human-readable description of the first violation found.
SheetManagement(String)
A sheet-management operation
(add_sheet,
insert_sheet,
rename_sheet,
move_sheet) violated an invariant —
a duplicate sheet name under simple case folding (schema spec §2), a
name that is empty or exceeds the length limit (schema spec §3), the
per-workbook sheet cap (scope ADR Decision 5), an out-of-range tab
position, or an unknown sheet name. Carries a human-readable
description.
Mutation(String)
A workbook-level mutation
(set, define_name,
redefine_name) violated an invariant —
an empty-literal write (use clear), an unknown sheet, a syntactically
invalid formula for the locked engine, an invalid or non-canonical
named-range name/ref, a ref to a missing sheet (schema spec §7), a
duplicate name under simple case folding, or a per-mutation resource cap
(cells / text / array / formula / named-range count, scope ADR
Decision 5). Carries a human-readable description.
Trait Implementations§
Source§impl Clone for WorkbookError
impl Clone for WorkbookError
Source§fn clone(&self) -> WorkbookError
fn clone(&self) -> WorkbookError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for WorkbookError
impl Debug for WorkbookError
Source§impl Display for WorkbookError
impl Display for WorkbookError
impl Eq for WorkbookError
Source§impl Error for WorkbookError
impl Error for WorkbookError
1.30.0 · 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()