#include <string_helper.h>
|
template<typename... Args> |
static std::string | dim_value (std::string explicitValue, const std::string format, const Args...args) |
|
template<typename... Args> |
static std::string | string_format (const std::string &format, Args...args) |
|
static bool | isBlank (const std::string str) |
|
static std::string | tolower (std::string data) |
|
Definition at line 8 of file string_helper.h.
template<typename... Args>
static std::string lc::StringHelper::dim_value |
( |
std::string |
explicitValue, |
|
|
const std::string |
format, |
|
|
const Args... |
args |
|
) |
| |
|
inlinestatic |
::string formater for dim values
- Parameters
-
explicitValue | "coord: <>" would be coord: 10.3 |
format | passed to sprintf |
args | passed to snprinf |
- Returns
- std::string
Definition at line 20 of file string_helper.h.
22 size_t pos = explicitValue.find(
"<>");
23 if (pos !=std::string::npos)
27 if (explicitValue.empty())
30 if (explicitValue ==
" ")
static std::string string_format(const std::string &format, Args...args)
static bool lc::StringHelper::isBlank |
( |
const std::string |
str | ) |
|
|
inlinestatic |
Test if astd::string is blank, c
Definition at line 49 of file string_helper.h.
50 std::regex r(
"[\\s]");
51 std::string result = regex_replace(str, r,
"");
52 return result.length()==0;
template<typename... Args>
static std::string lc::StringHelper::string_format |
( |
const std::string & |
format, |
|
|
Args... |
args |
|
) |
| |
|
inlinestatic |
static std::string lc::StringHelper::tolower |
( |
std::string |
data | ) |
|
|
inlinestatic |
To lowercase std::string
Definition at line 78 of file string_helper.h.
79 std::transform(data.begin(), data.end(), data.begin(),
::tolower);
static std::string tolower(std::string data)
The documentation for this class was generated from the following file: