NotInSet Filter

template<typename T, T... Values>
struct NotInSet

Filter that accepts values NOT in a compile-time set.

This filter checks if the new value does NOT match any of the specified compile-time values, implementing set exclusion validation.

Since

v0.1.0

// Example: Reject error codes 0, -1, -2
Signal<int, 10, NotInSet<int, 0, -1, -2>> status(0);

Warning

  • At least one value must be provided.

  • Type T must support operator==.

Template Parameters:
typename T

Value type.

T... Values

Variadic values to reject.

Public Functions

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

See Also