#include <string>
Go to the source code of this file.
◆ equals() [1/2]
bool equals |
( |
const float |
x, |
|
|
const float |
y, |
|
|
float |
epsilon |
|
) |
| |
Consder to floats equal if they are within epsilon of each other.
Definition at line 42 of file Util.cpp.
◆ equals() [2/2]
bool equals |
( |
const double |
x, |
|
|
const double |
y, |
|
|
double |
epsilon |
|
) |
| |
Consder to floats equal if they are within epsilon of each other.
Definition at line 47 of file Util.cpp.
◆ stringToDouble()
double stringToDouble |
( |
const string & |
str | ) |
|
Take a string representing a decimal point number and convert it to a double.
Throws std::invalid_argument if the string does not hold a decimal point number.
Definition at line 30 of file Util.cpp.
◆ stringToFloat()
float stringToFloat |
( |
const string & |
str | ) |
|
Take a string representing a decimal point number and convert it to a float.
Throws std::invalid_argument if the string does not hold a decimal point number.
Definition at line 14 of file Util.cpp.