12 #ifndef ECL_CONVERTERS_CONVERTER_HPP_ 13 #define ECL_CONVERTERS_CONVERTER_HPP_ 19 #include <ecl/errors/handlers.hpp> 29 namespace converters {
33 ConverterBase() : error_handler(
ecl::
NoError) {};
34 virtual Error error()
const {
return error_handler; }
55 template <
typename Output,
typename Input =
void>
56 class Converter :
public converters::ConverterBase {
58 virtual ~Converter() {}
59 Output operator()(
const Input &input);
70 template <
typename Output>
71 class Converter<
Output,void> :
public converters::ConverterBase {
73 virtual ~Converter() {}
75 template <
typename Input>
76 Output operator()(
const Input &input);
90 template <
typename Output,
typename Input>
93 return typename Output::Converter()(input);
104 template <
typename Output>
105 template <
typename Input>
108 return typename Output::Converter()(input);
Output operator()(const Input &input)