pub struct ShaclValidator<'a> {
pub quins: &'a [NQuin],
pub shapes: [ShaclShape; 64],
pub shape_count: u8,
pub constraints: [ShaclConstraint; 256],
pub constraint_count: u16,
}Expand description
SHACL validator
Fields§
§quins: &'a [NQuin]§shapes: [ShaclShape; 64]§shape_count: u8§constraints: [ShaclConstraint; 256]§constraint_count: u16Implementations§
Source§impl<'a> ShaclValidator<'a>
impl<'a> ShaclValidator<'a>
pub fn new(quins: &'a [NQuin]) -> Self
Sourcepub fn add_constraint(
&mut self,
constraint: ShaclConstraint,
) -> Result<ConstraintId, String>
pub fn add_constraint( &mut self, constraint: ShaclConstraint, ) -> Result<ConstraintId, String>
Add a constraint
Sourcepub fn validate_node(
&self,
node: u64,
shape: &ShaclShape,
) -> Result<ValidationResult, String>
pub fn validate_node( &self, node: u64, shape: &ShaclShape, ) -> Result<ValidationResult, String>
Validate a node against a shape
Sourcepub fn validate_graph(&self) -> Result<Vec<ValidationResult>, String>
pub fn validate_graph(&self) -> Result<Vec<ValidationResult>, String>
Validate all shapes against the graph
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for ShaclValidator<'a>
impl<'a> RefUnwindSafe for ShaclValidator<'a>
impl<'a> Send for ShaclValidator<'a>
impl<'a> Sync for ShaclValidator<'a>
impl<'a> Unpin for ShaclValidator<'a>
impl<'a> UnsafeUnpin for ShaclValidator<'a>
impl<'a> UnwindSafe for ShaclValidator<'a>
Blanket Implementations§
§impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
Aggregate shares in an MPC protocol.
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.