32#ifndef DRAIN_CONVERT_FUNDAMENTAL
33#define DRAIN_CONVERT_FUNDAMENTAL
63 template <
class S,
class D>
65 void convert(
const S & src, D & dst){
67 std::stringstream sstr;
74 void convert(
const char * src, D & dst){
75 std::ostringstream sstr(src);
79 std::cerr << __FILE__ <<
" read of " << src <<
" failed with " << sstr.failbit << std::endl;
103 void convert(
const char * src, T & dst){
104 std::stringstream sstr(src);
112 void convert(
const T & src, D & dst){
119 void convert(
const S & src, T & dst){
128 std::stringstream sstr;
137 std::stringstream sstr;
Utility class with static conversions.
Definition Convert.h:92
static void convertTo(const S &src, T &dst)
Convert with cast target type.
Definition Convert.h:136
static void convert(const T &src, T &dst)
Trivial case: source and destination are of same class.
Definition Convert.h:98
static void convertFrom(const T &src, D &dst)
Convert with cast source type.
Definition Convert.h:127
Utility class with static conversions.
Definition Convert.h:51
static void convert(const T &src, T &dst)
Trivial case: source and destination are of same class.
Definition Convert.h:58
Definition DataSelector.cpp:1277