28 lines
604 B
C++
28 lines
604 B
C++
#ifndef SMO_SIMULATOR_THREAD_H
|
|
#define SMO_SIMULATOR_THREAD_H
|
|
|
|
#include <boost/asio/io_context.hpp>
|
|
#include <spinscale/co/invokers.h>
|
|
#include <spinscale/co/postingPromise.h>
|
|
|
|
namespace smo {
|
|
namespace simulator {
|
|
|
|
struct SimulatorThreadTag
|
|
{
|
|
static boost::asio::io_context &io_context();
|
|
};
|
|
|
|
template <typename T>
|
|
using SimulatorPostingPromise =
|
|
sscl::co::TaggedPostingPromise<T, SimulatorThreadTag>;
|
|
|
|
template <typename T>
|
|
using SimulatorViralPostingInvoker =
|
|
sscl::co::ViralPostingInvoker<SimulatorPostingPromise, T>;
|
|
|
|
} // namespace simulator
|
|
} // namespace smo
|
|
|
|
#endif // SMO_SIMULATOR_THREAD_H
|