pub struct Access {
pub solutions: Arc<Vec<Solution>>,
pub index: usize,
}Expand description
All necessary solution access required to check an individual predicate.
Fields§
§solutions: Arc<Vec<Solution>>The set of input data for each predicate being solved within the solution set.
We require all solutions in order to handle checking predicate exists.
index: usizeChecking is performed for one solution at a time. This index refers to
the checked predicate’s associated solution within the SolutionSet slice.
Implementations§
Source§impl Access
impl Access
Sourcepub fn new(solutions: Arc<Vec<Solution>>, solution_index: SolutionIndex) -> Self
pub fn new(solutions: Arc<Vec<Solution>>, solution_index: SolutionIndex) -> Self
A shorthand for constructing a SolutionAccess instance for checking
the predicate at the given index within the given solution.
This constructor assumes that the given mutable keys contract is correct for this solution. It is not checked by this function for performance.
Sourcepub fn this_solution(&self) -> &Solution
pub fn this_solution(&self) -> &Solution
The solution associated with the predicate currently being checked.
Panics in the case that self.index is out of range of the self.solutions slice.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Access
impl RefUnwindSafe for Access
impl Send for Access
impl Sync for Access
impl Unpin for Access
impl UnwindSafe for Access
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
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>
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