| 224 | |
| 225 | template<typename F, typename...T> |
| 226 | void PrintEventHeaderHelper_(EVENT_RECORD* eventRecord, EventMetadata* metadata, const wchar_t* propName, F&& propFunc, T&&...rest) |
| 227 | { |
| 228 | wprintf(L" %s=", propName); |
| 229 | |
| 230 | using ParamType = pmon::util::FunctionPtrTraits<F>::template ParameterType<0>; |
| 231 | propFunc(metadata->GetEventData<std::remove_cvref_t<ParamType>>(eventRecord, propName)); |
| 232 | |
| 233 | if constexpr (sizeof...(T)) { |
| 234 | PrintEventHeaderHelper_(eventRecord, metadata, rest...); |
| 235 | } |
| 236 | } |
| 237 | |
| 238 | template<typename...T> |
| 239 | void PrintEventHeader(EVENT_RECORD* eventRecord, EventMetadata* metadata, char const* name, std::tuple<T...> props) |