pub struct MultiPattern {
pub patterns: Vec<Pattern>,
pub name: String,
}Expand description
Multi-pattern rule with joins
Fields§
§patterns: Vec<Pattern>List of patterns that must all match
name: StringRule name
Implementations§
Source§impl MultiPattern
impl MultiPattern
Sourcepub fn with_pattern(self, pattern: Pattern) -> Self
pub fn with_pattern(self, pattern: Pattern) -> Self
Add pattern
Sourcepub fn match_all(
&self,
wm: &WorkingMemory,
) -> Vec<(Vec<FactHandle>, HashMap<Variable, FactValue>)>
pub fn match_all( &self, wm: &WorkingMemory, ) -> Vec<(Vec<FactHandle>, HashMap<Variable, FactValue>)>
Match all patterns (with variable binding across patterns)
Trait Implementations§
Source§impl Clone for MultiPattern
impl Clone for MultiPattern
Source§fn clone(&self) -> MultiPattern
fn clone(&self) -> MultiPattern
Returns a duplicate 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 moreAuto Trait Implementations§
impl Freeze for MultiPattern
impl RefUnwindSafe for MultiPattern
impl Send for MultiPattern
impl Sync for MultiPattern
impl Unpin for MultiPattern
impl UnwindSafe for MultiPattern
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