14 #ifndef SERIALIZATION_UNICODE_CAST_HPP_INCLUDED
15 #define SERIALIZATION_UNICODE_CAST_HPP_INCLUDED
20 #include <boost/utility/enable_if.hpp>
21 #include <boost/type_traits/is_arithmetic.hpp>
28 template<
typename oitor_t>
38 template<
typename value_type>
44 template<
typename Tret,
typename Tcheck>
58 template<
typename TD ,
typename TS>
65 typedef typename std::back_insert_iterator<TD> t_outputitor;
66 typedef typename TS::const_iterator t_inputitor;
71 t_outputitor inserter(res);
73 t_inputitor i1 = source.begin();
74 t_inputitor i2 = source.end();
83 std::cerr <<
"Failed to convert a string from " << t_impl_reader::get_name() <<
" to " << t_impl_writer::get_name() <<
"\n";
100 typedef typename std::back_insert_iterator<TD> t_outputitor;
105 t_outputitor inserter(res);
112 std::cerr <<
"Failed to convert a string from " << t_impl_reader::get_name() <<
" to " << t_impl_writer::get_name() <<
"\n";
iteratorwriter(oitor_t &out)
ucs4_convert_impl::enableif< TD, typename TS::value_type >::type unicode_cast(const TS &source)
GLuint const GLfloat * val
void push(value_type val)
Transforms an output iterator to a writer for ucs4_convert_impl functions.
Thrown by operations encountering invalid UTF-8 data.
void read(config &cfg, std::istream &in, abstract_validator *validator)
void write(std::ostream &out, configr_of const &cfg, unsigned int level)
GLsizei GLsizei GLchar * source