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

  result | Root TriggerResult to print.
  indent | Current indentation level (number of two-space indents); callers typically omit this parameter and let recursion handle it.

Example
  using gridfire::trigger::TriggerResult;
  TriggerResult leaf{"A>5", "Threshold passed", true, {}};
  TriggerResult root{"AND", "Both conditions true", true, {leaf}};
  gridfire::trigger::printWhy(root);
  gridfire::trigger::printWhy
  void printWhy(const TriggerResult &result, const int indent=0)
  Pretty-print a TriggerResult explanation tree to std::cout.
  Definition trigger_pprint.h:26
  gridfire::trigger::TriggerResult
  Definition trigger_result.h:23