31 lines
645 B
C++
31 lines
645 B
C++
|
|
#ifndef SMO_BODY_THREAD_H
|
||
|
|
#define SMO_BODY_THREAD_H
|
||
|
|
|
||
|
|
#include <boost/asio/io_service.hpp>
|
||
|
|
#include <spinscale/co/invokers.h>
|
||
|
|
#include <spinscale/co/postingPromise.h>
|
||
|
|
|
||
|
|
namespace smo {
|
||
|
|
namespace body {
|
||
|
|
|
||
|
|
struct BodyThreadTag
|
||
|
|
{
|
||
|
|
static boost::asio::io_service &io_service();
|
||
|
|
};
|
||
|
|
|
||
|
|
template <typename T>
|
||
|
|
using BodyPostingPromise =
|
||
|
|
sscl::co::TaggedPostingPromise<T, BodyThreadTag>;
|
||
|
|
|
||
|
|
using BodyNonViralPostingInvoker =
|
||
|
|
sscl::co::NonViralPostingInvoker<BodyPostingPromise>;
|
||
|
|
|
||
|
|
template <typename T>
|
||
|
|
using BodyViralPostingInvoker =
|
||
|
|
sscl::co::ViralPostingInvoker<BodyPostingPromise, T>;
|
||
|
|
|
||
|
|
} // namespace body
|
||
|
|
} // namespace smo
|
||
|
|
|
||
|
|
#endif // SMO_BODY_THREAD_H
|