12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- #ifndef BOOST_PROCESS_DETAIL_HANDLER_BASE_HPP
- #define BOOST_PROCESS_DETAIL_HANDLER_BASE_HPP
- #include <system_error>
- namespace boost { namespace process { namespace detail {
- template<template <class> class Template>
- struct make_handler_t
- {
- constexpr make_handler_t() {}
- template<typename Handler>
- constexpr Template<Handler> operator()(Handler handler) const {return Template<Handler>(handler);}
- template<typename Handler>
- constexpr Template<Handler> operator= (Handler handler) const {return Template<Handler>(handler);}
- template<typename Handler>
- constexpr Template<Handler> operator+=(Handler handler) const {return Template<Handler>(handler);}
- };
- struct handler_base
- {
- using resource_type = void;
- template <class Executor>
- void on_setup(Executor&) const {}
- template <class Executor>
- void on_error(Executor&, const std::error_code &) const {}
- template <class Executor>
- void on_success(Executor&) const {}
- };
- }}}
- #endif
|