tin  1.5.9
tsm::transport::m2m_adapter< Codec > Struct Template Reference

#include <transport.h>

Collaboration diagram for tsm::transport::m2m_adapter< Codec >:
Collaboration graph

Static Public Member Functions

template<typename Runtime , std::size_t MaxBytes>
static status receive (Runtime &runtime, m2m_frame< MaxBytes > const &frame)
 

Detailed Description

template<typename Codec>
struct tsm::transport::m2m_adapter< Codec >

M2M ingress adapter.

The Codec template argument is an application-defined decoder with this shape:

struct MyDecoder { using event_type = MyMachine::SomeEvent;

template<std::size_t N> static bool decode(tsm::transport::m2m_frame<N> const& frame, event_type& event); };

The adapter performs common transport checks, asks the decoder to construct the typed event, then sends that event to the local runtime. It does not know HSM states, transition tables, fieldbus drivers, or packet schemas.

Member Function Documentation

◆ receive()

template<typename Codec >
template<typename Runtime , std::size_t MaxBytes>
static status tsm::transport::m2m_adapter< Codec >::receive ( Runtime runtime,
m2m_frame< MaxBytes > const &  frame 
)
inlinestatic

The documentation for this struct was generated from the following file: