14 #ifndef ECL_CONVERTERS_CONVERTERS_INTEGERS_HPP_ 15 #define ECL_CONVERTERS_CONVERTERS_INTEGERS_HPP_ 43 class Converter<int,std::string> :
public converters::ConverterBase {
59 std::istringstream stream(input);
61 if ( !( stream >> i ) || (stream.get(c))) {
76 class Converter<int,char> :
public converters::ConverterBase {
89 if ( ( c <
'0' ) || (c >
'9') ) {
93 return static_cast<int>(c -
'0');
138 class Converter<int,char*> :
public converters::ConverterBase {
int operator()(char c) ecl_debug_throw_decl(StandardException)
Converts a char to an integer type.
Primary templates for the family of converter classes.
Primary template and general fallback for converter classes.
int operator()(const std::string &input) ecl_debug_throw_decl(StandardException)
Converts a string to an integer type.
#define ecl_debug_throw_decl(exception)
#define ecl_debug_throw(exception)