GreaterThan Filter

template<typename T, T Threshold>
struct GreaterThan

Filter that only accepts values greater than a specified threshold.

This filter compares the new value against a compile-time threshold, propagating only when the new value exceeds it.

Since

v0.1.0

// Example: Only propagate values greater than 100
Signal<int, 10, GreaterThan<int, 100>> temperature(0);

Warning

Only accepts arithmetic types (integral and floating-point).

Template Parameters:
typename T

Arithmetic type.

T Threshold

The threshold value.

Public Functions

inline bool operator()(const T &old_value, const T &new_value) const

See Also