12#if defined( _WIN32 ) || defined(__APPLE__) || defined(__ANDROID_NDK__)
16namespace alib {
namespace strings {
24template<
typename TChar>
27 struct lconv * lc=localeconv();
29 DecimalPointChar=
static_cast<TChar
>( *(lc->decimal_point) );
30 ThousandsGroupChar=
static_cast<TChar
>( *(lc->thousands_sep) );
33template<
typename TChar>
36 if ( other ==
nullptr )
44 template<
typename TChar>
45 void setComputational( TNumberFormat<TChar>& nf )
47 nf.Flags = NumberFormatFlags::ForceDecimalPoint;
48 nf.DecimalPointChar =
'.';
49 nf.Whitespaces = TT_CStringConstants<TChar>::DefaultWhitespaces();
53 nf.DecMinimumFieldWidth=
57 nf.IntegralPartMinimumWidth=
58 nf.FractionalPartWidth= -1;
61 nf.LeadingGroupCharReplacement=
' ';
63 nf.ThousandsGroupChar=
',';
65 nf.BinNibbleGroupChar=
67 nf.HexWord32GroupChar=
68 nf.OctGroupChar=
'\'';
70 nf.HexByteGroupChar=
'\0';
71 nf.BinByteGroupChar=
'-';
72 nf.BinWordGroupChar=
'=';
73 nf.BinWord32GroupChar=
'#';
81 setComputational( *
this );
83 ExponentSeparator =
"E" ;
86 BinLiteralPrefix =
"0b" ;
87 HexLiteralPrefix =
"0x" ;
88 OctLiteralPrefix =
"0o" ;
94 setComputational( *
this );
96 ExponentSeparator =
A_WCHAR(
"E" ) ;
99 BinLiteralPrefix =
A_WCHAR(
"0b" ) ;
100 HexLiteralPrefix =
A_WCHAR(
"0x" ) ;
101 OctLiteralPrefix =
A_WCHAR(
"0o" ) ;
107 setComputational( *
this );
109 ExponentSeparator =
A_XCHAR(
"E" ) ;
110 INFLiteral =
A_XCHAR(
"INF" ) ;
111 NANLiteral =
A_XCHAR(
"NAN" ) ;
112 BinLiteralPrefix =
A_XCHAR(
"0b" ) ;
113 HexLiteralPrefix =
A_XCHAR(
"0x" ) ;
114 OctLiteralPrefix =
A_XCHAR(
"0o" ) ;
@ Global
Denotes the global (singleton) scope.