idfxx 1.0.0
Modern C++23 components for ESP-IDF
Loading...
Searching...
No Matches
idfxx::event_data Concept Reference

Concept for types that can be both received and posted as event data. More...

Concept definition

template<typename T>
concept idfxx::event_data = receivable_event_data<T> && std::is_trivially_copyable_v<T>
Concept for types that can be both received and posted as event data.
Definition event.hpp:164
Concept for types that can be received as event data.
Definition event.hpp:146

Detailed Description

Concept for types that can be both received and posted as event data.

A type satisfies event_data if it can be received and is trivially copyable, allowing ESP-IDF to memcpy it into the event queue. Trivially copyable types satisfy both this and receivable_event_data without needing from_opaque.

Types that are only received (e.g., system event data from ESP-IDF that wraps non-trivial C++ types) need only satisfy receivable_event_data.

Template Parameters
TThe type to check.

Definition at line 164 of file event.hpp.