add Space::to_float(...), to_double(...) and to_long_double(...) methods
This commit is contained in:
@@ -1277,6 +1277,27 @@ unsigned long long Space::to_ulong_long(const wchar_t * field, unsigned long lon
|
||||
return space ? space->to_ulong_long() : default_value;
|
||||
}
|
||||
|
||||
float Space::to_float(const wchar_t * field, float default_value) const
|
||||
{
|
||||
const Space * space = get_space(field);
|
||||
return space ? space->to_float() : default_value;
|
||||
}
|
||||
|
||||
|
||||
double Space::to_double(const wchar_t * field, double default_value) const
|
||||
{
|
||||
const Space * space = get_space(field);
|
||||
return space ? space->to_double() : default_value;
|
||||
}
|
||||
|
||||
|
||||
long double Space::to_long_double(const wchar_t * field, long double default_value) const
|
||||
{
|
||||
const Space * space = get_space(field);
|
||||
return space ? space->to_long_double() : default_value;
|
||||
}
|
||||
|
||||
|
||||
std::string Space::to_str(const wchar_t * field, const char * default_value) const
|
||||
{
|
||||
const Space * space = get_space(field);
|
||||
|
Reference in New Issue
Block a user