--- trunk/OOPSE-4/src/utils/StringUtils.hpp 2005/01/14 16:49:46 1945 +++ trunk/OOPSE-4/src/utils/StringUtils.hpp 2005/02/01 22:49:23 1962 @@ -113,10 +113,22 @@ namespace oopse { template std::string toString(const T& v) { std::ostringstream oss; - oss << v; + if (!oss << v) { + std::cerr << "toString Error" << std::endl; + } return oss.str(); } + template + T lexi_cast(const std::string& str) { + T result; + std::istringstream iss; + if (iss >> result) { + std::cerr << "lexi_cast Error" << std::endl; + } + return result; + } + /**@todo need implementation */ std::string getPrefix(const std::string& str);