manipulator.hpp
Go to the documentation of this file.
1 
8 /*****************************************************************************
9 ** Ifdefs
10 *****************************************************************************/
11 
12 #ifndef ECL_STREAMS_MANIPULATOR_HPP_
13 #define ECL_STREAMS_MANIPULATOR_HPP_
14 
15 /*****************************************************************************
16 ** Includes
17 *****************************************************************************/
18 
19 #include <ecl/config/macros.hpp>
20 #include <ecl/concepts/devices.hpp>
21 #include "../macros.hpp"
22 
23 /*****************************************************************************
24 ** Namespaces
25 *****************************************************************************/
26 
27 namespace ecl {
28 
29 /*****************************************************************************
30 ** Forwarding
31 *****************************************************************************/
32 
33 namespace interfaces {
34  template <typename Device, bool OutputDevice> class ECL_PUBLIC OutputTextStream;
35 }
36 
37 /*****************************************************************************
38 ** Interface [Manipulator]
39 *****************************************************************************/
91 template <typename Derived>
92 class ecl_streams_PUBLIC Manipulator {
93 public:
108  template <typename ODevice>
109  void insert (interfaces::OutputTextStream<ODevice,true>& ostream) {
110  ecl_compile_time_concept_check(OutputCharDeviceConcept<ODevice>);
111  static_cast<Derived*>(this)->action(ostream);
112  }
113 
114  virtual ~Manipulator() {}
115 };
116 
117 } // namespace ecl
118 
119 #endif /* ECL_STREAMS_MANIPULATOR_HPP_ */
ecl_compile_time_concept_check
#define ecl_compile_time_concept_check(Model)
ecl_streams_PUBLIC
#define ecl_streams_PUBLIC
Definition: macros.hpp:37
devices.hpp
macros.hpp
ecl::interfaces::OutputTextStream
class ECL_PUBLIC OutputTextStream
Definition: manipulator.hpp:48
ecl
ECL_PUBLIC
#define ECL_PUBLIC


ecl_streams
Author(s): Daniel Stonier
autogenerated on Sun Aug 2 2020 03:12:20