GridFire v0.7.0_rc2
General Purpose Nuclear Network
Loading...
Searching...
No Matches
gridfire::trigger Namespace Reference

Namespaces

namespace  solver
 

Classes

class  AndTrigger
 Logical conjunction of two triggers with short-circuit evaluation. More...
 
class  EveryNthTrigger
 Pass-through trigger that fires every Nth time its child trigger is true. More...
 
class  LogicalTrigger
 
class  NotTrigger
 Logical negation of a trigger. More...
 
class  OrTrigger
 Logical disjunction of two triggers with short-circuit evaluation. More...
 
class  Trigger
 Generic trigger interface for signaling events/conditions during integration. More...
 
struct  TriggerResult
 

Functions

void printWhy (const TriggerResult &result, const int indent=0)
 Pretty-print a TriggerResult explanation tree to std::cout.
 

Function Documentation

◆ printWhy()

void gridfire::trigger::printWhy ( const TriggerResult & result,
const int indent = 0 )
inline

Pretty-print a TriggerResult explanation tree to std::cout.

Prints one line per node prefixed with Unicode bullets and indentation to visualize the explanation hierarchy. Each line shows [TRUE|FALSE], the node name, and description.

Parameters
resultRoot TriggerResult to print.
indentCurrent indentation level (number of two-space indents); callers typically omit this parameter and let recursion handle it.
Example
TriggerResult leaf{"A>5", "Threshold passed", true, {}};
TriggerResult root{"AND", "Both conditions true", true, {leaf}};
void printWhy(const TriggerResult &result, const int indent=0)
Pretty-print a TriggerResult explanation tree to std::cout.
Definition trigger_pprint.h:26
Definition trigger_result.h:23