pub enum BranchType {
IfElse {
condition: String,
then_branch: NodeId,
else_branch: NodeId,
},
Switch {
key: String,
cases: HashMap<String, NodeId>,
default: Option<NodeId>,
},
}Expand description
Type of branch node for conditional execution paths.
Variants§
IfElse
If-else: evaluate condition on predecessor output, choose then_branch
or else_branch node.
Fields
Switch
Switch-case: match a key against multiple values, each mapping to a different successor node.
Trait Implementations§
Source§impl Clone for BranchType
impl Clone for BranchType
Source§fn clone(&self) -> BranchType
fn clone(&self) -> BranchType
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 BranchType
impl Debug for BranchType
Source§impl<'de> Deserialize<'de> for BranchType
impl<'de> Deserialize<'de> for BranchType
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
Auto Trait Implementations§
impl Freeze for BranchType
impl RefUnwindSafe for BranchType
impl Send for BranchType
impl Sync for BranchType
impl Unpin for BranchType
impl UnsafeUnpin for BranchType
impl UnwindSafe for BranchType
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