pub enum CausaloidType {
Singleton,
Collection,
Graph,
}Expand description
Represents the structural type of a Causaloid.
This enum is a key part of the Causaloid’s internal design. It allows a
Causaloid to act as a polymorphic container, holding either a single causal
element, a collection of elements, or a complex causal graph.
The primary use of CausaloidType is to dispatch method calls like verify
or explain to the appropriate underlying implementation based on the structure
it contains. This avoids dynamic dispatch (e.g., dyn Trait) and keeps the
Causaloid’s data layout concrete and efficient.
§Variants
Singleton- Represents aCausaloidcontaining a single, indivisible causal unit. This is the most basic form.Collection- Represents aCausaloidcontaining a collection of otherCausaloids, typically stored in aVec. The elements in the collection are treated as independent units for reasoning.Graph- Represents aCausaloidcontaining a directed acyclic graph (DAG) of otherCausaloids. This structure allows for modeling complex causal
Variants§
Trait Implementations§
Source§impl Clone for CausaloidType
impl Clone for CausaloidType
Source§fn clone(&self) -> CausaloidType
fn clone(&self) -> CausaloidType
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 moreSource§impl Debug for CausaloidType
impl Debug for CausaloidType
Source§impl Display for CausaloidType
impl Display for CausaloidType
Source§impl PartialEq for CausaloidType
impl PartialEq for CausaloidType
Source§impl PartialOrd for CausaloidType
impl PartialOrd for CausaloidType
impl Copy for CausaloidType
impl StructuralPartialEq for CausaloidType
Auto Trait Implementations§
impl Freeze for CausaloidType
impl RefUnwindSafe for CausaloidType
impl Send for CausaloidType
impl Sync for CausaloidType
impl Unpin for CausaloidType
impl UnwindSafe for CausaloidType
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