pub enum Binding {
Attribute(AttributeBinding),
Not(AntijoinBinding),
Constant(ConstantBinding),
BinaryPredicate(BinaryPredicateBinding),
}
Expand description
Binding types supported by Hector.
Variants§
Attribute(AttributeBinding)
Two variables bound by (e,v) pairs from an attribute.
Not(AntijoinBinding)
Variables that must not be bound by the wrapped binding.
Constant(ConstantBinding)
A variable bound by a constant value.
BinaryPredicate(BinaryPredicateBinding)
Two variables bound by a binary predicate.
Implementations§
Source§impl Binding
impl Binding
Sourcepub fn binary_predicate(predicate: BinaryPredicate, x: u32, y: u32) -> Binding
pub fn binary_predicate(predicate: BinaryPredicate, x: u32, y: u32) -> Binding
Creates a BinaryPredicateBinding.
Trait Implementations§
Source§impl AsBinding for Binding
impl AsBinding for Binding
Source§fn binds(&self, variable: u32) -> Option<usize>
fn binds(&self, variable: u32) -> Option<usize>
Iff the binding has opinions about the given variable, this will
return the offset, otherwise None.
Source§fn ready_to_extend(&self, prefix: &dyn AsBinding) -> Option<u32>
fn ready_to_extend(&self, prefix: &dyn AsBinding) -> Option<u32>
Returns an optional variable by which this binding could
extend the given prefix.
Source§fn required_to_extend(
&self,
prefix: &dyn AsBinding,
target: u32,
) -> Option<Option<u32>>
fn required_to_extend( &self, prefix: &dyn AsBinding, target: u32, ) -> Option<Option<u32>>
Returns an optional variable which must be bound by the prefix
in order for this binding to extend the prefix. If None, then
this binding can never be used to extend the prefix to the
specified variable (e.g. because it doesn’t even bind it).
Source§impl<'de> Deserialize<'de> for Binding
impl<'de> Deserialize<'de> for Binding
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Ord for Binding
impl Ord for Binding
Source§impl PartialOrd for Binding
impl PartialOrd for Binding
impl Eq for Binding
impl StructuralPartialEq for Binding
Auto Trait Implementations§
impl Freeze for Binding
impl RefUnwindSafe for Binding
impl Send for Binding
impl Sync for Binding
impl Unpin for Binding
impl UnwindSafe for Binding
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