Function template for_each_field
boost::pfr::for_each_field
Synopsis
template<typename T, typename F> ( value, func);
Description
Calls func
for each field of a value
.
Example:
Parameters: |
func
|
must have one of the following signatures:
any_return_type func(U&& field) // field of value is perfect forwarded to function
any_return_type func(U&& field, std::size_t i)
any_return_type func(U&& value, I i) // Here I is an std::integral_constant<size_t, field_index>
|
value
|
To each field of this variable will be the func applied. |
|