|
#ifndef __STDSTRING_HELPER_H_
#define __STDSTRING_HELPER_H_
#pragma warning ( push, 1 )
#include <iostream> // cin, cout, cerr
#include <sstream> // new and improved
#include <string> // string
#include <locale> // narrow to wide, wide to narrow
#include <cctype> // toupper, tolower
#include <algorithm> // transform
#pragma warning( pop )
#ifdef UNICODE
# define _tcout wcout
# define _tcerr wcerr
# define _tcin wcin
# define _tclog wclog
#else
# define _tcout cout
# define _tcerr cerr
# define _tcin cin
# define _tclog clog
#endif
#ifdef UNICODE
# define _tstringbuf wstringbuf
# define _tistringstream wistringstream
# define _tostringstream wostringstream
#else
# define _tstringbuf stringbuf
# define _tistringstream istringstream
# define _tostringstream ostringstream
#endif
#ifdef UNICODE
# define _tstring wstring
#else
# define _tstring string
#endif
bool Find( const std::string&, const std::string& );
bool Find( const std::wstring&, const std::wstring& );
std::wstring StringWiden( const std::string& narrow );
std::string StringNarrow( const std::wstring& wide );
std::wstring StringUpper( const std::wstring& wide );
std::string StringUpper( const std::string& wide );
std::wstring StringLower( const std::wstring& wide );
std::string StringLower( const std::string& wide );
#endif // __STDSTRING_HELPER_H_
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.