Combines child conditions with logical operators. More...
| Header: | #include <CompositeCondition> |
| Since: | 1.0 |
| Inherits: | ConditionBase |
(since 1.0) enum class | LogicalOp { AND, OR, NOT, OP_COUNT } |
CompositeCondition groups multiple conditions together using AND, OR, or NOT operators. Supports nested composition for complex boolean logic.
Children are evaluated in the order they were added. AND stops at the first false child and OR at the first true child.
See also LogicalOp, ICondition, and ConditionFactory.
[since 1.0] enum class LogicalOpThe operator a CompositeCondition applies to its children.
| Constant | Value | Description |
|---|---|---|
CompositeCondition::LogicalOp::AND | 0 | True when every child is true. Evaluation stops at the first false child. |
CompositeCondition::LogicalOp::OR | 1 | True when one child is true. Evaluation stops at the first true child. |
CompositeCondition::LogicalOp::NOT | 2 | The inverse of the one child. With more than one child, the result is false and a warning is logged. |
CompositeCondition::LogicalOp::OP_COUNT | 3 | The number of operators, not an operator. cycle() steps through the operators modulo this value. |
This enum was introduced in 1.0.