Home | Info | Community | Development | myReactOS | Contact Us
ReactOS Development > Doxygen_numpunct.h
Go to the documentation of this file.
00001 /* 00002 * Copyright (c) 1999 00003 * Silicon Graphics Computer Systems, Inc. 00004 * 00005 * Copyright (c) 1999 00006 * Boris Fomitchev 00007 * 00008 * This material is provided "as is", with absolutely no warranty expressed 00009 * or implied. Any use is at your own risk. 00010 * 00011 * Permission to use or copy this software for any purpose is hereby granted 00012 * without fee, provided the above notices are retained on all copies. 00013 * Permission to modify the code and to distribute modified code is granted, 00014 * provided the above notices are retained, and a notice that the code was 00015 * modified is included with the above copyright notice. 00016 * 00017 */ 00018 // WARNING: This is an internal header file, included by other C++ 00019 // standard library headers. You should not attempt to use this header 00020 // file directly. 00021 00022 00023 #ifndef _STLP_INTERNAL_NUMPUNCT_H 00024 #define _STLP_INTERNAL_NUMPUNCT_H 00025 00026 #ifndef _STLP_IOS_BASE_H 00027 # include <stl/_ios_base.h> 00028 #endif 00029 00030 # ifndef _STLP_C_LOCALE_H 00031 # include <stl/c_locale.h> 00032 # endif 00033 00034 #ifndef _STLP_INTERNAL_STRING_H 00035 # include <stl/_string.h> 00036 #endif 00037 00038 _STLP_BEGIN_NAMESPACE 00039 00040 //---------------------------------------------------------------------- 00041 // numpunct facets 00042 00043 template <class _CharT> class numpunct {}; 00044 template <class _CharT> class numpunct_byname {}; 00045 template <class _Ch, class _InIt> class num_get; 00046 00047 _STLP_TEMPLATE_NULL 00048 class _STLP_CLASS_DECLSPEC numpunct<char> : public locale::facet { 00049 public: 00050 typedef char char_type; 00051 typedef string string_type; 00052 00053 explicit numpunct(size_t __refs = 0) 00054 : locale::facet(__refs) {} 00055 00056 char decimal_point() const { return do_decimal_point(); } 00057 char thousands_sep() const { return do_thousands_sep(); } 00058 string grouping() const { return do_grouping(); } 00059 string truename() const { return do_truename(); } 00060 string falsename() const { return do_falsename(); } 00061 00062 static _STLP_STATIC_DECLSPEC locale::id id; 00063 00064 protected: 00065 ~numpunct(); 00066 00067 virtual char do_decimal_point() const; 00068 virtual char do_thousands_sep() const; 00069 virtual string do_grouping() const; 00070 virtual string do_truename() const; 00071 virtual string do_falsename() const; 00072 }; 00073 00074 # if ! defined (_STLP_NO_WCHAR_T) 00075 00076 _STLP_TEMPLATE_NULL 00077 class _STLP_CLASS_DECLSPEC numpunct<wchar_t> : public locale::facet { 00078 public: 00079 typedef wchar_t char_type; 00080 typedef wstring string_type; 00081 00082 explicit numpunct(size_t __refs = 0) 00083 : locale::facet(__refs) {} 00084 00085 wchar_t decimal_point() const { return do_decimal_point(); } 00086 wchar_t thousands_sep() const { return do_thousands_sep(); } 00087 string grouping() const { return do_grouping(); } 00088 wstring truename() const { return do_truename(); } 00089 wstring falsename() const { return do_falsename(); } 00090 00091 static _STLP_STATIC_DECLSPEC locale::id id; 00092 00093 protected: 00094 ~numpunct(); 00095 00096 virtual wchar_t do_decimal_point() const; 00097 virtual wchar_t do_thousands_sep() const; 00098 virtual string do_grouping() const; 00099 virtual wstring do_truename() const; 00100 virtual wstring do_falsename() const; 00101 }; 00102 00103 # endif /* WCHAR_T */ 00104 00105 _STLP_TEMPLATE_NULL 00106 class _STLP_CLASS_DECLSPEC numpunct_byname<char> : public numpunct<char> { 00107 friend class _Locale_impl; 00108 public: 00109 typedef char char_type; 00110 typedef string string_type; 00111 00112 explicit numpunct_byname(const char* __name, size_t __refs = 0); 00113 00114 protected: 00115 00116 ~numpunct_byname(); 00117 00118 virtual char do_decimal_point() const; 00119 virtual char do_thousands_sep() const; 00120 virtual string do_grouping() const; 00121 virtual string do_truename() const; 00122 virtual string do_falsename() const; 00123 00124 private: 00125 numpunct_byname(_Locale_numeric *__numeric) 00126 : _M_numeric(__numeric) {} 00127 00128 //explicitely defined as private to avoid warnings: 00129 typedef numpunct_byname<char> _Self; 00130 numpunct_byname(_Self const&); 00131 _Self& operator = (_Self const&); 00132 00133 _Locale_numeric* _M_numeric; 00134 }; 00135 00136 # ifndef _STLP_NO_WCHAR_T 00137 _STLP_TEMPLATE_NULL 00138 class _STLP_CLASS_DECLSPEC numpunct_byname<wchar_t>: public numpunct<wchar_t> { 00139 friend class _Locale_impl; 00140 public: 00141 typedef wchar_t char_type; 00142 typedef wstring string_type; 00143 00144 explicit numpunct_byname(const char* __name, size_t __refs = 0); 00145 00146 protected: 00147 ~numpunct_byname(); 00148 00149 virtual wchar_t do_decimal_point() const; 00150 virtual wchar_t do_thousands_sep() const; 00151 virtual string do_grouping() const; 00152 virtual wstring do_truename() const; 00153 virtual wstring do_falsename() const; 00154 00155 private: 00156 numpunct_byname(_Locale_numeric *__numeric) 00157 : _M_numeric(__numeric) {} 00158 00159 //explicitely defined as private to avoid warnings: 00160 typedef numpunct_byname<wchar_t> _Self; 00161 numpunct_byname(_Self const&); 00162 _Self& operator = (_Self const&); 00163 00164 _Locale_numeric* _M_numeric; 00165 }; 00166 00167 # endif /* WCHAR_T */ 00168 00169 _STLP_END_NAMESPACE 00170 00171 #endif /* _STLP_NUMPUNCT_H */ 00172 00173 // Local Variables: 00174 // mode:C++ 00175 // End: 00176 Generated on Sun May 27 2012 04:29:20 for ReactOS by
1.7.6.1
|