Annotation of truecrypt/platform/stringconverter.h, revision 1.1.1.1

1.1       root        1: /*
                      2:  Copyright (c) 2008 TrueCrypt Foundation. All rights reserved.
                      3: 
                      4:  Governed by the TrueCrypt License 2.4 the full text of which is contained
                      5:  in the file License.txt included in TrueCrypt binary and source code
                      6:  distribution packages.
                      7: */
                      8: 
                      9: #ifndef TC_HEADER_Platform_StringConverter
                     10: #define TC_HEADER_Platform_StringConverter
                     11: 
                     12: #include <stdlib.h>
                     13: #include "PlatformBase.h"
                     14: 
                     15: namespace TrueCrypt
                     16: {
                     17:        class StringConverter
                     18:        {
                     19:        public:
                     20:                static wstring FromNumber (double number);
                     21:                static wstring FromNumber (int number);
                     22:                static wstring FromNumber (int64 number);
                     23:                static wstring FromNumber (long number);
                     24:                static wstring FromNumber (unsigned int number);
                     25:                static wstring FromNumber (unsigned long number);
                     26:                static wstring FromNumber (uint64 number);
                     27:                static string GetTrailingNumber (const string &str);
                     28:                static string GetTypeName (const type_info &typeInfo);
                     29:                static wstring QuoteSpaces (const wstring &str);
                     30:                static vector <string> Split (const string &str, const string &separators = " \t\r\n", bool returnEmptyFields = false);
                     31:                static wstring ToExceptionString (const exception &ex);
                     32:                static uint32 ToUInt32 (const string &str);
                     33:                static uint32 ToUInt32 (const wstring &str);
                     34:                static uint64 ToUInt64 (const string &str);
                     35:                static uint64 ToUInt64 (const wstring &str);
                     36:                static string ToSingle (const wstring &str, bool noThrow = false);
                     37:                static wstring ToWide (const string &str, bool noThrow = false);
                     38:                static void ToWideBuffer (const wstring &str, wchar_t *buffer, size_t bufferSize);
                     39:                static string Trim (const string &str);
                     40: 
                     41:        private:
                     42:                StringConverter ();
                     43:        };
                     44: }
                     45: 
                     46: #endif // TC_HEADER_Platform_StringConverter

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.