|
microfmt
Zero-allocation C++ formatting for constrained environments
|
Compile-time register field queried through typed callbacks. More...
#include <register_context.hpp>
Public Types | |
| using | state_type = State |
| using | value_type = Value |
Static Public Member Functions | |
| static constexpr bool | matches (uint32_t index) noexcept |
| static bool | read (const state_type &state, address_space_ref space, uint32_t index, value_type &value) noexcept |
| template<auto Callback = WriteCallback, typename std::enable_if< Callback !=nullptr, int >::type = 0> | |
| static bool | write (state_type &state, address_space_ref space, uint32_t index, const value_type &value) noexcept |
Compile-time register field queried through typed callbacks.
This supports registers that are not stored in the bound state, including values read directly from hardware. Passing nullptr as WriteCallback creates a read-only field.
| State | Bound context state. |
| Value | Register value type. |
| ReadCallback | Nothrow callback that reads a register value. |
| WriteCallback | Nothrow callback that writes a register value, or nullptr. |
| Registers | Register indexes handled by the callbacks. |
| using microfmt::register_callback_field< State, Value, ReadCallback, WriteCallback, Registers >::state_type = State |
| using microfmt::register_callback_field< State, Value, ReadCallback, WriteCallback, Registers >::value_type = Value |
|
inlinestaticconstexprnoexcept |
|
inlinestaticnoexcept |
|
inlinestaticnoexcept |