42 std::string output =
source;
44 for (; (
j = output.find(
find)) != std::string::npos;)
52 transform(output.begin(), output.end(), output.begin(),
::toupper);
59 transform(output.begin(), output.end(), output.begin(),
::tolower);
75 if (
input.size() == 0)
77 std::string
temp =
"";
79 if (
begpos == std::string::npos) {
99 throw "StringUtils::toBool() - Not a bool: " +
trimmedInput;
111 std::stringstream
ss(
str);
113 std::vector<std::string>
list;
122 std::stringstream
ss;
125 std::regex re(
ss.str());
126 std::sregex_token_iterator
first{
input.begin(),
input.end(), re, -1 },
148 std::vector<unsigned int> v;
175 std::vector<double> v;
187 std::ostringstream
stream;
192template std::string StringUtil::toString<int>(
const int &
t);
196 if (
input.length() >= end.length()) {
197 return (0 ==
input.compare(
input.length() - end.length(), end.length(), end));
static std::string trim(const std::string &input, const std::string &trim=std::string(" \t\n"))
static std::vector< double > toDoubleVector(const std::string &s)
static std::vector< int > toIntVector(const std::string &s)
static std::string makeUpper(const std::string &instring)
static std::vector< unsigned int > toUintVector(const std::string &s)
static std::string makeLower(const std::string &instring)
std::vector< std::string > split(const std::string &str, char delim=' ')
static std::vector< std::string > split(const std::string &input, const std::string &delim=" ")
static bool endsWith(const std::string &input, const std::string &end)
static std::string pad(const std::string &input, char pad, int length)
static int toInt(const std::string &input)
static bool toBool(const std::string &input)
static std::string findAndReplace(const std::string &source, const std::string &find, const std::string &replace)
static double toDouble(const std::string &input)
static std::vector< bool > toBoolVector(const std::string &s)
static bool contains(const std::string &source, const char *find)
static float toFloat(const std::string &input)
static std::string toString(const T &t)
static std::vector< std::string > toStringVector(const std::string &s)
std::shared_ptr< T > SPtr