Renamed compile time state machine classes

This commit is contained in:
John Wellbelove 2022-01-22 21:11:18 +00:00
parent fc59b4e34e
commit 2353672b64
5 changed files with 885 additions and 835 deletions

View File

@ -196,7 +196,7 @@ namespace etl
const etl::state_chart_traits::state<TObject>* State_Table_Begin,
size_t State_Table_Size,
etl::state_chart_traits::state_id_t Initial_State>
class state_chart_ctv : public istate_chart<void>
class state_chart_ct : public istate_chart<void>
{
public:
@ -209,7 +209,7 @@ namespace etl
//*************************************************************************
/// Constructor.
//*************************************************************************
ETL_CONSTEXPR state_chart_ctv()
ETL_CONSTEXPR state_chart_ct()
: current_state_id(Initial_State)
, started(false)
{
@ -271,7 +271,7 @@ namespace etl
/// that satisfies the conditions for executing the action.
/// \param event_id The id of the event to process.
//*************************************************************************
virtual void process_event(event_id_t event_id/*, parameter_t data*/) ETL_OVERRIDE
virtual void process_event(event_id_t event_id) ETL_OVERRIDE
{
if (started)
{
@ -379,8 +379,8 @@ namespace etl
};
// Disabled
state_chart_ctv(const state_chart_ctv&) ETL_DELETE;
state_chart_ctv& operator =(const state_chart_ctv&) ETL_DELETE;
state_chart_ct(const state_chart_ct&) ETL_DELETE;
state_chart_ct& operator =(const state_chart_ct&) ETL_DELETE;
state_id_t current_state_id; ///< The current state id.
bool started; ///< Set if the state chart has been started.
@ -399,7 +399,7 @@ namespace etl
const etl::state_chart_traits::state<TObject>* State_Table_Begin,
size_t State_Table_Size,
etl::state_chart_traits::state_id_t Initial_State>
class state_chart_ct : public istate_chart<TParameter>
class state_chart_ctp : public istate_chart<TParameter>
{
public:
@ -412,7 +412,7 @@ namespace etl
//*************************************************************************
/// Constructor.
//*************************************************************************
ETL_CONSTEXPR state_chart_ct()
ETL_CONSTEXPR state_chart_ctp()
: current_state_id(Initial_State)
, started(false)
{
@ -586,8 +586,8 @@ namespace etl
};
// Disabled
state_chart_ct(const state_chart_ct&) ETL_DELETE;
state_chart_ct& operator =(const state_chart_ct&) ETL_DELETE;
state_chart_ctp(const state_chart_ctp&) ETL_DELETE;
state_chart_ctp& operator =(const state_chart_ctp&) ETL_DELETE;
state_id_t current_state_id; ///< The current state id.
bool started; ///< Set if the state chart has been started.

View File

@ -224,6 +224,8 @@ set(TEST_SOURCE_FILES
test_state_chart.cpp
test_state_chart_with_data_parameter.cpp
test_state_chart_with_rvalue_data_parameter.cpp
test_state_chart_compile_time.cpp
test_state_chart_compile_time_with_data_parameter.cpp
test_string_char.cpp
test_string_char_external_buffer.cpp
test_string_stream.cpp
@ -255,7 +257,7 @@ set(TEST_SOURCE_FILES
test_type_lookup.cpp
test_type_select.cpp
test_type_traits.cpp
# test_unaligned_type.cpp
test_unaligned_type.cpp
test_unordered_map.cpp
test_unordered_multimap.cpp
test_unordered_multiset.cpp

View File

@ -232,13 +232,13 @@ namespace
MotorControl motorControl;
etl::state_chart_ctv<MotorControl,
motorControl,
transitionTable,
7,
stateTable,
3,
StateId::IDLE> motorControlStateChart;
etl::state_chart_ct<MotorControl,
motorControl,
transitionTable,
7,
stateTable,
3,
StateId::IDLE> motorControlStateChart;
SUITE(test_state_chart_compile_time)
{

View File

@ -238,7 +238,7 @@ namespace
MotorControl motorControl;
etl::state_chart_ct<MotorControl,
etl::state_chart_ctp<MotorControl,
int,
motorControl,
transitionTable,

File diff suppressed because it is too large Load Diff