#[non_exhaustive]pub enum Error {
Io {
path: PathBuf,
source: Error,
},
Bundle {
message: String,
},
Checksum {
path: String,
expected: String,
actual: String,
},
NotXml {
line: u32,
column: u32,
message: String,
},
Unsupported {
message: String,
},
Transform {
stylesheet: String,
code: String,
line: Option<u32>,
message: String,
},
Internal {
message: String,
},
}Expand description
Why a rule set could not be loaded, or a document could not be validated.
Validity problems of a document (schema errors, failed asserts) are not errors: they
are in the Report. An error means that no complete verdict could
be given.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Io
A file could not be read.
Bundle
The bundle is not usable: a manifest that does not follow the format, a missing file, an unknown schema name, a stylesheet that is not well-formed XSLT, or one whose result is not an SVRL report.
Checksum
A file of the bundle does not have the SHA-256 its manifest records.
Fields
NotXml
The document is not well-formed XML (or not UTF-8, or not namespace-well-formed).
Unsupported
The document or a rule-set artefact needs a construct that this engine does not implement (an encoding other than UTF-8, a document type declaration, an XSLT or XML Schema construct outside the supported subset). Refused rather than answered differently from the reference engine.
Transform
A stylesheet of the rule set raised a dynamic error on the document (the reference engine fails on it as well).
Fields
Internal
A bug of this engine: a result it cannot read back.
Implementations§
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()