|
Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
|
#include "Utils.h"
Go to the source code of this file.
Functions | |
| bool | ends_with (const std::string &str, const std::string &suffix) |
| Tests whether a string ends with a given suffix. | |
| std::vector< std::string > | split (const std::string &s, char delimiter) |
| Splits a string into parts using a single-character delimiter. | |
| std::string | doubleToString (double value, int precision) |
| Converts a double to a fixed-format string with a given precision. | |
| std::string | to_lowercase (const std::string &str) |
| Returns a lowercase copy of the input string. | |
| std::string doubleToString | ( | double | value, |
| int | precision | ||
| ) |
Converts a double to a fixed-format string with a given precision.
The output uses std::fixed formatting and precision digits after the decimal point.
| value | Floating-point value to convert. |
| precision | Number of digits after the decimal point. |
value. | bool ends_with | ( | const std::string & | str, |
| const std::string & | suffix | ||
| ) |
| std::vector< std::string > split | ( | const std::string & | s, |
| char | delimiter | ||
| ) |
Splits a string into parts using a single-character delimiter.
Consecutive delimiters yield empty tokens. The delimiter itself is not included in the resulting strings.
Example:
| s | Input string to split. |
| delimiter | Character used as separator. |
| std::string to_lowercase | ( | const std::string & | str | ) |