⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 std_ex.h

📁 一个小巧的嵌入式图形系统wGUI, 可以用VC编译
💻 H
字号:
// std_ex.h//// Extensions to the std library////// Copyright (c) 2002 Rob Wiskow// rob-dev@boxedchaos.com//// This library is free software; you can redistribute it and/or// modify it under the terms of the GNU Lesser General Public// License as published by the Free Software Foundation; either// version 2.1 of the License, or (at your option) any later version.//// This library is distributed in the hope that it will be useful,// but WITHOUT ANY WARRANTY; without even the implied warranty of// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU// Lesser General Public License for more details.//// You should have received a copy of the GNU Lesser General Public// License along with this library; if not, write to the Free Software// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA//#include <string>#include <list>namespace stdex{//! Converts an integer to it's string representation//! \param iValue The integer to convert to a string//! \return A std::string representing the valuestd::string itoa(const int iValue);//! Converts a long integer to it's string representation//! \param lValue The integer to convert to a string//! \return A std::string representing the valuestd::string ltoa(const long lValue);//! Converts a double to it's string representation//! \param fValue The double to convert to a string//! \return A std::string representing the valuestd::string ftoa(const float fValue);//! Converts a double to it's string representation//! \param dValue The double to convert to a string//! \return A std::string representing the valuestd::string dtoa(const double dValue);//! Converts a string to it's int representation//! \param sValue the string to convert//! \return integerint atoi(const std::string& sValue);//! Converts a string to it's long integer representation//! \param sValue the string to convert//! \return long integerlong int atol(const std::string& sValue);//! Converts a string to it's float representation//! \param sValue the string to convert//! \return floatfloat atof(const std::string& sValue);//! Converts a string to it's double representation//! \param sValue the string to convert//! \return doubledouble atod(const std::string& sValue);//! Trim the whitespace (spaces and tabs) from the beginning and end of a string//! \param sString The string to be trimmed//! \return the trimmed stringstd::string TrimString(const std::string& sString);//! Detokenize a string given a list of delimiters//! \param sString The string to be tokenized//! \param sDelimiters A string of delimiter characters//! \return A list of string tokensstd::list<std::string> DetokenizeString(const std::string& sString, const std::string& sDelimiters);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -