pub enum ValidationError {
FileLoading {
filename: String,
contents: String,
msg: String,
},
MissingRequiredRule {
rule_type: Rule,
},
InvalidRule {
rule: Rule,
msg: String,
},
InvalidRuleType {
rule_type: Rule,
msg: String,
},
UndefinedRuleCall {
term: Term,
},
ResourceBlock {
term: Term,
msg: String,
},
SingletonVariable {
term: Term,
},
UnregisteredClass {
term: Term,
},
DuplicateResourceBlockDeclaration {
resource: Term,
declaration: Term,
existing: Declaration,
new: Declaration,
},
}
Variants§
FileLoading
MissingRequiredRule
InvalidRule
InvalidRuleType
UndefinedRuleCall
The policy contains a call to an undefined rule. This is the validation analogue of
RuntimeError::QueryForUndefinedRule
.
ResourceBlock
SingletonVariable
UnregisteredClass
DuplicateResourceBlockDeclaration
Trait Implementations§
Source§impl AsRef<str> for ValidationError
impl AsRef<str> for ValidationError
Source§impl Clone for ValidationError
impl Clone for ValidationError
Source§fn clone(&self) -> ValidationError
fn clone(&self) -> ValidationError
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ValidationError
impl Debug for ValidationError
Source§impl Display for ValidationError
impl Display for ValidationError
Source§impl From<ValidationError> for PolarError
impl From<ValidationError> for PolarError
Source§fn from(err: ValidationError) -> Self
fn from(err: ValidationError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ValidationError
impl RefUnwindSafe for ValidationError
impl Send for ValidationError
impl Sync for ValidationError
impl Unpin for ValidationError
impl UnwindSafe for ValidationError
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