32 #ifndef STRING_UTILITIES_H 33 #define STRING_UTILITIES_H 63 bool toDouble(
const std::string&
string,
double& value);
73 bool toFloat(
const std::string&
string,
float& value);
83 bool toInt32(
const std::string&
string, int32_t& value, int32_t base = 10);
93 bool toUInt32(
const std::string&
string, uint32_t& value, int32_t base = 10);
103 int8_t
toInt8(
const std::string&
string, int8_t& value, int32_t base = 10);
113 uint8_t
toUInt8(
const std::string&
string, uint8_t& value, int32_t base = 10);
128 #endif // STRING_UTILITIES_H bool toFloat(const std::string &string, float &value)
Interprets the contents of "string" as a floating point number of type float.
bool toDouble(const std::string &string, double &value)
Interprets the contents of "string" as a floating point number of type double It stores the "string"'...
uint8_t toUInt8(const std::string &string, uint8_t &value, int32_t base)
Interprets the contents of "string" as a floating point number of whatever unsigned integer type your...
bool toUInt32(const std::string &string, uint32_t &value, int32_t base)
Interprets the contents of "string" as a floating point number of whatever unsigned integer type your...
int8_t toInt8(const std::string &string, int8_t &value, int32_t base)
Interprets the contents of "string" as a floating point number of whatever integer type your system h...
std::string trimString(std::string str)
Removes trailing zeros from a string representing a float or double except for the first zero after t...
bool toInt32(const std::string &string, int32_t &value, int32_t base)
Interprets the contents of "string" as a floating point number of whatever integer type your system h...