Added a simple non-optimized StringTokenizer-class for tokenizing strings. Also added a contains(char)-function to the String-class because it was handy in implementing the StringTokenizer.

svn-id: r30828
This commit is contained in:
Kari Salminen 2008-02-08 04:11:20 +00:00
parent e3852c92a7
commit b6cad0f0ce
4 changed files with 58 additions and 0 deletions

View file

@ -226,6 +226,10 @@ bool String::contains(const char *x) const {
return strstr(c_str(), x) != NULL;
}
bool String::contains(char x) const {
return strchr(c_str(), x) != NULL;
}
void String::deleteLastChar() {
deleteChar(_len - 1);
}