template<typename T, auto Condition, bool StoredAsOptional = true>
struct ProtocolCraft::Internal::Conditioned< T, Condition, StoredAsOptional >
A type wrapper to conditionally serialize a type.
- Template Parameters
-
T | Underlying type, can be VarType or DiffType too |
Condition | A condition function pointer to a non static const class member function returning a bool, i.e. bool(*Class::Condition)(const Class*) const |
StoredAsOptional | If true, T will be stored as empty std::optional when Condition is not satisfied instead of default initialized values |
Definition at line 82 of file Templates.hpp.