Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/boost/process/v1/detail/handler_base.hpp was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // Copyright (c) 2006, 2007 Julio M. Merino Vidal
0002 // Copyright (c) 2008 Ilya Sokolov, Boris Schaeling
0003 // Copyright (c) 2009 Boris Schaeling
0004 // Copyright (c) 2010 Felipe Tanus, Boris Schaeling
0005 // Copyright (c) 2011, 2012 Jeff Flinn, Boris Schaeling
0006 // Copyright (c) 2016 Klemens D. Morgenstern
0007 //
0008 // Distributed under the Boost Software License, Version 1.0. (See accompanying
0009 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
0010 
0011 #ifndef BOOST_PROCESS_DETAIL_HANDLER_BASE_HPP
0012 #define BOOST_PROCESS_DETAIL_HANDLER_BASE_HPP
0013 
0014 #include <boost/process/v1/detail/config.hpp>
0015 #include <system_error>
0016 
0017 namespace boost { namespace process { BOOST_PROCESS_V1_INLINE namespace v1 { namespace detail {
0018 
0019 template<template <class> class Template>
0020 struct make_handler_t
0021 {
0022     constexpr make_handler_t() {}
0023     template<typename Handler>
0024     constexpr Template<Handler> operator()(Handler handler) const {return Template<Handler>(handler);}
0025     template<typename Handler>
0026     constexpr Template<Handler> operator= (Handler handler) const {return Template<Handler>(handler);}
0027     template<typename Handler>
0028     constexpr Template<Handler> operator+=(Handler handler) const {return Template<Handler>(handler);}
0029 };
0030 
0031 
0032 struct handler_base
0033 {
0034     using resource_type = void;
0035 
0036     template <class Executor>
0037     void on_setup(Executor&) const {}
0038 
0039     template <class Executor>
0040     void on_error(Executor&, const std::error_code &) const {}
0041 
0042     template <class Executor>
0043     void on_success(Executor&) const {}
0044 
0045 };
0046 
0047 
0048 }}}}
0049 
0050 #endif