'startswith' util function for strings

This commit is contained in:
Dennis Luxen 2011-07-06 12:32:57 +00:00
parent 5ef8afe7c4
commit 4883c6c197

View File

@ -107,4 +107,8 @@ std::string HTMLDeEntitize( std::string result) {
}
return result;
}
bool StringStartsWith(string & input, string & prefix) {
return (input.find(prefix) == 0);
}
#endif /* STRINGUTIL_H_ */