rust-rule-engine 1.20.1

A blazing-fast Rust rule engine with RETE algorithm, backward chaining inference, and GRL (Grule Rule Language) syntax. Features: forward/backward chaining, pattern matching, unification, O(1) rule indexing, TMS, expression evaluation, method calls, streaming with Redis state backend, watermarking, and custom functions. Production-ready for business rules, expert systems, real-time stream processing, and decision automation.
Documentation
//! BetaNode: joins multiple AlphaMemory

use super::memory::AlphaMemory;

#[derive(Debug, Clone)]
pub struct BetaNode {
    pub left: AlphaMemory,
    pub right: AlphaMemory,
}

impl BetaNode {
    pub fn join(&self) -> Vec<((String, String), (String, String))> {
        let mut result = Vec::new();
        for l in &self.left.matches {
            for r in &self.right.matches {
                result.push((l.clone(), r.clone()));
            }
        }
        result
    }
}