#[non_exhaustive]pub enum DefinitionError {
Yaml(YamlError),
Target {
kind: String,
target: String,
source: PathError,
},
SourcePath {
kind: String,
path: String,
},
Overlap {
kind: String,
first: String,
second: String,
},
Reserved {
kind: String,
target: String,
reason: &'static str,
},
Unconditional {
kind: String,
},
NoKinds,
}Expand description
A source definition that cannot be loaded.
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.
Yaml(YamlError)
The file is not acceptable YAML, or does not have the shape of a source definition.
Target
A path into the OCSF event cannot be parsed.
Fields
SourcePath
A path into the decoded record cannot be parsed.
Overlap
Two fields write the same attribute, or one writes inside another, so one of them would be lost.
Fields
Reserved
A field writes an attribute the definition may not set directly.
Fields
Unconditional
A kind has no condition, so it would accept every record and hide the kinds after it.
NoKinds
The definition has no kinds, so every record would be rejected.
Trait Implementations§
Source§impl Clone for DefinitionError
impl Clone for DefinitionError
Source§impl Debug for DefinitionError
impl Debug for DefinitionError
Source§impl Display for DefinitionError
impl Display for DefinitionError
impl Eq for DefinitionError
Source§impl Error for DefinitionError
impl Error for DefinitionError
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<YamlError> for DefinitionError
impl From<YamlError> for DefinitionError
Source§impl PartialEq for DefinitionError
impl PartialEq for DefinitionError
impl StructuralPartialEq for DefinitionError
Auto Trait Implementations§
impl Freeze for DefinitionError
impl RefUnwindSafe for DefinitionError
impl Send for DefinitionError
impl Sync for DefinitionError
impl Unpin for DefinitionError
impl UnsafeUnpin for DefinitionError
impl UnwindSafe for DefinitionError
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