cxWidgets 1.0
Namespaces | Functions
cxStringUtils.h File Reference
#include <regex.h>
#include <cctype>
#include <string>
#include <vector>
#include <list>
#include <sstream>
#include "cxReturnCodes.h"
#include "cxKeyDefines.h"
#include "cxInputOptions.h"
#include "cxBorderStyles.h"
Include dependency graph for cxStringUtils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  cxStringUtils
 String utility functions.
 

Functions

void cxStringUtils::SplitStringRegex (const std::string &input, const std::string &regex, std::vector< std::string > &resultContainer)
 
bool cxStringUtils::Find (const std::string &input, const std::string &regex, bool useBasicRegex=false)
 
void cxStringUtils::Find (const std::string &input, const std::string &regex, std::string &output)
 
bool cxStringUtils::Replace (std::string &srcStr, const std::string &regexStr, const std::string &replacementStr)
 
std::string cxStringUtils::replace (const std::string &input, const std::string &search, const std::string &replace)
 Replaces substrings of a string with another string.
 
int cxStringUtils::stringTo (const std::string &s)
 Converts a string to another type.
 
long cxStringUtils::stringToLong (const std::string &s)
 
unsigned cxStringUtils::stringToUnsigned (const std::string &s)
 
double cxStringUtils::stringToDouble (const std::string &s)
 
long double cxStringUtils::stringToLongDouble (const std::string &s)
 
std::string cxStringUtils::stringToString (const std::string &s)
 
void cxStringUtils::test_stringTo ()
 
std::string cxStringUtils::toString (const int &x)
 Converts an object to a string, i.e.:
 
std::string cxStringUtils::toString (const long &x)
 
std::string cxStringUtils::toString (const double &x)
 
std::string cxStringUtils::toString (const long double &x)
 
std::string cxStringUtils::toString (const unsigned &x)
 
std::string cxStringUtils::toString (const unsigned long &x)
 
std::string cxStringUtils::toString (const cx::eReturnCode &x)
 
std::string cxStringUtils::toString (const cx::eInputOptions &x)
 
std::string cxStringUtils::toString (const cx::eBorderStyle &x)
 
std::string cxStringUtils::toString (const void *x)
 
void cxStringUtils::test_toString ()
 
bool cxStringUtils::startsWithNumber (const std::string &pStr)
 
bool cxStringUtils::isPrintable (const int &pKey)
 Returns whether or not a key is printable. This should be used.
 
int cxStringUtils::indexOfLastCap (const std::string &pStr)
 Returns the index of the last capital letter in a string. Returns -1 if there are no capital letters.
 
void cxStringUtils::toUpper (std::string &theString)
 Converts a string to upper-case.
 
std::string cxStringUtils::stripNewlines (const std::string &pStr)
 Strips newlines characters from a string and returns.
 
std::string cxStringUtils::replaceNewlines (const std::string &pStr, const char &pChar)
 Replaces newlines in a string with another character.
 
void cxStringUtils::insertUnderline (std::string &pStr, char pChar, bool pAll=false)
 Inserts an underline character into.
 
std::string cxStringUtils::removeChar (const std::string &pString, const int pPos)
 Removes a character from a string.
 
std::string cxStringUtils::strToUpper (const std::string &theString)
 conver the string to upper case
 
std::string cxStringUtils::strToLower (const std::string &theString)
 conver the string to lower case
 
void cxStringUtils::TrimSpaces (std::string &str)
 Trims leading & trailing spaces from a string.
 
void cxStringUtils::splitStringOnNewlines (const std::string &pStr, std::list< std::string > &pStrings)
 Splits a string on newlines.