ES-DE/src/Util.cpp

22 lines
395 B
C++
Raw Normal View History

#include "Util.h"
std::string strToUpper(const char* from)
{
std::string str(from);
for(unsigned int i = 0; i < str.size(); i++)
str[i] = toupper(from[i]);
return str;
}
std::string& strToUpper(std::string& str)
{
for(unsigned int i = 0; i < str.size(); i++)
str[i] = toupper(str[i]);
return str;
}
std::string strToUpper(const std::string& str)
{
return strToUpper(str.c_str());
}